HTTP or HTTPS
Posted: Sun Jul 26, 2009 2:49 pm
Hello,
I'm a bit new at PHP so please be patient. Thanks
I need to get the "full" url of any given web page from my website, (it must be the complete url)
example: [http://mysite.com/directory/document.extension]
and assign that URL value to a variable.
I've tried (locally) the values of HTTP_REFERER, PHP_SELF, REQUEST_URI, and several others and the best I come up with is:
mysite.com/directory/document.extension, etc..., but as you can see the URL is missing the [http://] part, which happens to be what I'm after.
I need to determine the connection. Is it:
http or https ?
Once the type of connection has been determined, then the rest of my code will work.
Thanks
I'm a bit new at PHP so please be patient. Thanks
I need to get the "full" url of any given web page from my website, (it must be the complete url)
example: [http://mysite.com/directory/document.extension]
and assign that URL value to a variable.
I've tried (locally) the values of HTTP_REFERER, PHP_SELF, REQUEST_URI, and several others and the best I come up with is:
mysite.com/directory/document.extension, etc..., but as you can see the URL is missing the [http://] part, which happens to be what I'm after.
I need to determine the connection. Is it:
http or https ?
Once the type of connection has been determined, then the rest of my code will work.
Thanks