- time: documentation ( source)
- date: documentation ( source)
<?php
$duration = 15;
$t_time = 1411387095 ;
$then = time() - $duration*60;
echo date('Y-m-d H:i:s',$t_time)."\r\n";
echo date('Y-m-d H:i:s',$then )."\r\n";
if($t_time >= $then) {
echo 'ok';
}