Forum Moderators: coopster
_http://www.webmasterworld.com/redir.cgi?f=3&d=12127&url=_http://domain.com_
I'm looking to find a simple script that performs the action of redir.cgi. I can't even see the need for it to log the number of times external URLs are being called upon.
Any ideas? I've looked on HotScripts, PHPBuilder, etc... To no avail. I'm a newbie to any sort of scripting work.
A simple redir.php would use the header() function to send a "Location" header to the browser, which will trundle off to the new location.
usage:
redir.php?url=http://www.example.com/
<?php
// do whatever logging you want to do with $url (update counter in database for example)
header("Location: " . $url);
exit();
?>
That's it!