Jump to content

[SOLVED] how do i add 30 minutes to my time!!!!


suresh64633

Recommended Posts

Got the Answer:

$startTime = 07:00 AM
for($loop=1;$loop<=5;$loop++)
{
$event_length = 30*$loop;
$timestamp = strtotime("$startTime");
$etime = strtotime("+$event_length minutes", $timestamp);
echo $next_time = date('h:i A', $etime)."<br />";
}

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.