Thread: PHP help?
View Single Post
Old 01-28-2006, 03:25 AM  
Tempest
Too lazy to set a custom title
 
Industry Role:
Join Date: May 2004
Location: West Coast, Canada.
Posts: 10,217
Quote:
Originally Posted by TeenGodFather
well,
I send them from say
http://ww.url.com/page.shtml
that page as a hyperlink
<a hreF="/cgi-bin/script.cgi?=http://www.urlwiththecode.com>link</A>

So basically I send to the cgi-bin page, which in turn sends them to the 'end page'. So which is the referer? The page where user clicks the link, or the cgi-script that redirects them to the right place?
Ah... Well if I remember correctly (haven't checked that sort of detailed thing in awhile), it's "usually" the page and not the script.. But.. it's not 100% and I'm not sure why that is.. Could be different browser types or could be spiders/crawlers. Perhaps you should run a test script or something.. setup your links to send to a test page and have that test page display the referer.

<?php
echo("'$HTTP_SERVER_VARS['HTTP_REFERER']'");
?>

There IS another server variables for "redirect" referers as well. Can't remember the name of it right now.
Tempest is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote