The website (wwww.fake-web-site.com) redirects its links to my website (www.real-web-site.com). Only the first page is different.
I wrote code to redirect all the people who came from a fake site to google.com.
if (strpos($_SERVER['HTTP_REFERER'],'fake-web-site.com') !== false) header('Location: http://www.google.com/search?q=real-web-site.com');
It works in the Chrome browser, if someone opens a fake website and clicks on the links that are associated with my site, it will be redirected to google.com. After that, he can open my site with google.com.
In Firefox, if someone opens a fake website and clicks on the links that are related to my site, he will be redirected to google.com after that, if he clicks on real-web-site.com on google.com, it redirects again to google.com!
I think this is due to the Firefox caching mechanism. Can someone give a suggestion?
source share