unix time stam for midnight php code example
Example: php get start of today
$beginOfDay = strtotime("today");
//to format
//$beginOfDay = date("Y-m-d H:i:s",strtotime('today'));
$beginOfDay = strtotime("today");
//to format
//$beginOfDay = date("Y-m-d H:i:s",strtotime('today'));