evet demek istediğim oydu
SQL
Alıntı
CREATE TABLE `linkkontrol_gunler` (
`id` int(5) NOT NULL auto_increment,
`url` varchar(50) NOT NULL,
`hit` int(15) NOT NULL,
`gun` varchar(10) NOT NULL,
PRIMARY KEY (`id`)
);
INSERT INTO `linkkontrol_gunler` (`id`, `url`, `hit`, `gun`) VALUES(1, 'http://www.google.com', 500, '8.9.2008');
Cron oluşturup hergün 23:59 da bunu çalıştırırsın.
linkkontrol_gunler.php <?php
$bagla = mysql_connect('localhost', 'root', 'rootpass');
mysql_select_db('dbname');
$sonuc = mysql_query("Select * From linkkontrol");
while($satir = mysql_fetch_assoc($sonuc)){
mysql_query("Insert Into linkkontrol_gunler (url, hit, gun) Values ('".$satir[url]."', '".$satir[hit]."', '".date('d.m.Y ', time())."')");
mysql_query("Update linkkontrol Set hit=0 where id = ".$satir[id]);
}
?>linkkontrol_gunler tablosunda hergünün hiti ayrı ayrı tutulmuş olur yanlış bişey yoksa tabi.