php - Countdown for 7 hours then show ok -


how can countdown 7 hours variable time (i time table inserted timestamp), after 7 hours variable time update table.

i need that

$time = 2013-05-18 02:00:00 // comes database $target = $time + 7hours // time database +7hours 2013-05-18 09:00:00 $until = $target - $time 

i need below code

if ($until > 0 ) {     echo "you need wait $until hours" } else {     echo "time ok"; // update table } 

convert time string using strtotime($time)+25200 7 hour =60*60*7=25200 sec , check , add file cron job.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -