Hi,
I’m trying to track from where my users comes (based on $_SERVER[‘HTTP_REFERER’] I mark them as google, direct or other) and then pass this info via $_SESSIONS through all they clicks over the site to the contact form page and send it with email.
So to do that I did some PHP in my header that’s embed on every page, where I:
1) start sessions
2) parse the referer to get my “track_id”
3) check, if referer is from my site (means user passing my site)
4) if no -> store “track_id” in my $_SESSION[‘track_id’]
5) if yes -> do nothing
That’s all I’m doing there. Then, at my contact form page I read this session data and put it into hidden input.
All works just perfect beside Firefox - no matter if it’s FF 2, 3, 3.5, on windows, linuks or osx
After my debugging it looks like in FF the PHP in header is run two times after each click and for the first time $_SERVER[‘HTTP_REFERER’] is empty and the second time it’s my site - like it should be.
So the problem is, why just Firefox run it two times???
May it be because of RewriteEngine used to remove index.php? But only in FF? Strange!
I need your help. please!