Obtaining the URL

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
$_SERVER["SERVER_NAME"] and $_SERVER["HTTP_HOST"] are good and all, but none
of them are reliable.

Eg: Not all subdomains will have a vhost entry for them in Apache, or the
Host: header is not filled in.

So are there any other methods of determining the URL of the script itself?


Re: Obtaining the URL

Quoted text here. Click to load it
Quoted text here. Click to load it

The answer is no, as the URL itself is not passed in the request.

Site Timeline