I am working on a small script that is looking to see if one time is more than 30 minutes after another time. It is trying to work through some of my web stats to see if the visitor is a new visit. It does not seem to be working though. Hope you can help, here is my code: $accessed = mysql_result($Result,0,"access_time"); list($date, $time) = explode(' ', $accessed); list($year, $month, $day) = explode('-', $date); list($hour, $minute, $second) = explode(':', $time); $dateaccessed = mktime($hour, $minute, $second, $month, $day, $year); $temptime = strtotime("30 minutes", $dateaccessed); if($dateaccessed > $temptime) { $newvisit = "Y"; } else { $newvisit = "N"; } PHP: