envexlabs Posted May 26, 2008 Share Posted May 26, 2008 Hey, I have a script that figures out the difference between 2 times. So lets say i have a time difference of 2:36. I need to figure out what 2:36 would be in number form and i'm not a math whiz. So if 1:15 would be 1.25 as a number, how would i figure out all the other numbers. Sorry if this is confusing, it's kind of hard to explain. Thanks, envex. Link to comment https://forums.phpfreaks.com/topic/107320-figuring-out-time-as-a-whole-number/ Share on other sites More sharing options...
BlueSkyIS Posted May 26, 2008 Share Posted May 26, 2008 number of seconds in a minute: 60. so divide the number of seconds by 60: 1:15 = 1 + 15/60 = 1.25 ditto'ish for minutes/hours Link to comment https://forums.phpfreaks.com/topic/107320-figuring-out-time-as-a-whole-number/#findComment-550243 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.