Not as PHP Geeky as I Thought I Was
October 22nd, 2008
I want to get some info from an organic visitor, such as the HTTP_REFERER and such. I know how to get that and turn it into a variable, but for the life of me I can’t figure out how to keep that referer variable static. In other words, as the visitor bounces around the website, I don’t want it to change at every page. I want to keep just their original referer (ie google, yahoo, etc).
Now, once they end up at the contact_us page and fill out a form, I want to email that original referer information to myself as a hidden input item.
How can I save a variable and keep it from changing as they bounce through the site? I’m sure it has something to do with PHP sessions but I can’t get it to work no matter what I try.



