How to get time value using PHP same as TIMEVALUE() function in Excel -


here have 1 string contain "00:01:00" in excel sheet, pass string timevalue() function of excel return 0.000694 same way want in php.

is there function performing task, or other way achieve goal?

an excel timestamp float 24 hours 1 day, 1 hour 1/24th.

calculate difference between timestamp values 00:01:00 , 00:00:00, divide number of seconds in day

$x = strtotime("00:01:00"); $y = strtotime("00:00:00");  echo ($x - $y) / 86400, php_eol; 

Comments