I believe or think you mean referer or what page referred you to the current page
$ref = $SERVER['HTTP_REFERER'];
$remote_ip = $SERVER['REMOTE_ADDR'];
There U go, and there's the IP of the user requesting the page at no extra cost...
Remember, if someone arrives at your page by typing in the URL there really is no referer
Enjoy!!!!