obay Posted July 22, 2009 Share Posted July 22, 2009 what is wrong with this statement? strtotime("07-23-2009 01:40:58"); because when i date("yyyy-mm-dd",strtotime("07-23-2009 01:40:58")); it returns 1970-01-01 when it's supposed to return 2009-07-23 any help appreciated. thanks Link to comment https://forums.phpfreaks.com/topic/167019-solved-strtotime-question/ Share on other sites More sharing options...
obay Posted July 22, 2009 Author Share Posted July 22, 2009 i found the answer to my own question dashes should be replaced with slashes that is, strtotime("07/23/2009 01:40:58"); instead of strtotime("07-23-2009 01:40:58"); Link to comment https://forums.phpfreaks.com/topic/167019-solved-strtotime-question/#findComment-880628 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.