Jump to content
php.lv forumi

Nodzest pec 24h


Troxy

Recommended Posts

Ka nodzest ierakstu kuram ir beidzies deriguma terminsh

 

 

id codes time expire

1 1111 1215798060 296000

 

<?php
$con = mysql_connect("localhost","root","normal");
if (!$con)
 {
 die('Could not connect: ' . mysql_error());
 }
//izvelas datubazi, kur saglabasies kods
mysql_select_db("amxx", $con);
//ievada datubaze kodu
$resulty = mysql_query("DELETE FROM codes WHERE expire<$time");                   

mysql_close($con);

?>

Link to comment
Share on other sites

uztaisi, lai tev log failu taisa varbut tev tas $time tiek padots nepareizi, un vai tev ir dazadi ieraksti ar dazadiem laikiem.

Link to comment
Share on other sites

×
×
  • Create New...