File size: 703B
<?php
Error_Reporting(E_ALL & ~E_NOTICE);
Error_Reporting (ERROR | WARNING);
include'../config.php';
include'../include/head.php';
if(@fopen ("http://$f", "r"))
{
header("location: http://$f");
$file = fopen("../data/link_count/$f","r");
$zapis = fread($file, 100);
$count = ($zapis + 1);
fclose($file);
$file2 = fopen("../data/link_count/$f","a+");
flock ($file2,LOCK_EX);
ftruncate ($file2,0);
fputs($file2, $count);
fflush ($file2);
flock ($file2,LOCK_UN);
fclose($file2);
chmod ("../data/link_count/$f", 0666);
}
else
{
echo "<div><br/><br/>Ошибка, Невозможно зайти на требуемый вам сайт !</a></div>";}
include'../include/foot.php';
?>