Full-service Internet Marketing & Web Development
Recent Posts

Sponsors
![]() |
Simple File URL RedirectCode Wizard, 12-30-2006 |
This script makes it easy to redirect to anotehr page, anotehr site, or a file on the server. It appends it to two seperate files through two seperate variables.
<?php // ver 4.0 FINAL
//
// By : Andrew Heebner
//
if(isset($url)):
$fpl = fopen("url_log.txt","a");
$log = sprintf("%s | %s | %s | %s", date("d.M.Y H:i:s"), $HTTP_REFERER, $url, gethostbyaddr($REMOTE_ADDR));
fputs($fpl, "$log<br>
");
fclose($fpl);
$url = escapeshellcmd($url);
Header("Location: $url")
elseif(isset($fid)):
$fpf = fopen("file_log.txt","a");
$log = sprintf("%s | %s | %s", date("d.M.Y H:i:s"), basename($fid), gethostbyaddr($REMOTE_ADDR));
fputs($fpf, "$log<br>
");
fclose($fpf);
$fid = escapeshellcmd($fid);
Header("Location: $fid");
endif;
?>
|
|
Subscribe Now to receive new posts via Email as soon as they come out.
Comments
Post your comments

