SERVER_IP => SERVER_NAME. For getting absRootURL.

I must be wrote that code in a very bad condition.