flemingmike Posted January 14, 2011 Share Posted January 14, 2011 hello, what am i doing wrong? $starttime=$row['starttime']; $esttime1=date( 'g:i a', strtotime(-2 hours, $starttime) ); Link to comment https://forums.phpfreaks.com/topic/224471-strtotime-question/ Share on other sites More sharing options...
Pikachu2000 Posted January 14, 2011 Share Posted January 14, 2011 What is the data type of the `starttime` field? And are you just trying to unconditionally subtract 2 hours from every record returned? Link to comment https://forums.phpfreaks.com/topic/224471-strtotime-question/#findComment-1159572 Share on other sites More sharing options...
requinix Posted January 15, 2011 Share Posted January 15, 2011 "-2 hours" needs to be a string. Link to comment https://forums.phpfreaks.com/topic/224471-strtotime-question/#findComment-1159586 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.