Question: how to subtract hours and minutes in php?
Answer: php $date = new DateTime('Y-m-d H:i:s'); $date->sub(new DateInterval('PT10H30S')); echo $date->format('Y-m-d H:i:s');?> To subtract 15 minutes you can do: date('Y-m-d H:i:s', (time() - 60 * 15)); You can replace 15 with the number of minutes you want.