note 50077 deleted from reserved.variables by felipe

[email protected]
Newsgroups php.notes
Message-ID <[email protected]>
Note Submitter:  

----

grlprgrmmr wrote:

you can use these to reconstructed the current page url.

<?php

echo 'http';
if($_SERVER['HTTPS']=='on'){echo 's';}
echo '://'.$_SERVER['SERVER_PORT'].$_SERVER['SCRIPT_NAME'];
if($_SERVER['QUERY_STRING']>' '){echo '?'.$_SERVER['QUERY_STRING'];}

?>
______________

the $_SERVER['SERVER_PORT'] part should be changed to $_SERVER['HTTP_HOST']
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.