Possible Duplicate:
PHP Get the Full URL
How do I capture the whole URL using PHP?
I would like to the whole of the URL including the _GET variable names and values, for example www.mywebsite.com/store.php?department=MENS
The code I have used below only gives me the URL without the _GET variable part.
$url = $_SERVER['SERVER_NAME'];
$page = $_SERVER['PHP_SELF'];
$page = $_POST['url'];
echo "http://".$url.$page;
All I would like is to be able to copy that URL exactly how it is.