datetime add seconds php code example
Example 1: how to add hour minute seconds in php datetime
date('Y-m-d H:i',strtotime('+1 hour +20 minutes',strtotime($start)));
Example 2: add seconds to datetime php
<?php
$date = new DateTime();
echo $date->getTimestamp(). "<br>";
$date->add(new DateInterval('PT674165S')); // adds 674165 secs
echo $date->getTimestamp();
?>