Forum Moderators: coopster
It then sends a 301 Moved header and a header location for the new url (external domain). Most of the time this works absolutely fine.
<?php
..database functions removed...
header("HTTP/1.1 301 Moved Permanently");
header("Location: $url");
?>
In some cases (maybe once per day) a client will click a link, which opens the html of the new page, but the images are attempted to be loaded from my domain. I haven't been able to reproduce this myself, even with several months testing, but in the logs I can see the client hit the go.php?id=343 page, then they request all the images for that page from my site, resulting in a load of 404's.
There does not seem to be any pattern to the user agent, sometimes IE6 others Firefox or IE7
Any Ideas?
Thanks
Regards
Tim
Do you have images in the script after the redirect part? Try adding an exit to the code; something like the following:
header("HTTP/1.1 301 Moved Permanently");
header("Location: $url");
[url=http://www.php.net/exit]exit[/url];