ted_chou12 Posted December 19, 2006 Share Posted December 19, 2006 My format of the time is this:12/19/06 04:27 amhowever, I need to get it into this format:11447893the standard php time format,how would I do that? thanksbtw I think i saw someone posted this before, but I cant seem to find it.Ted. Link to comment https://forums.phpfreaks.com/topic/31237-chaging-the-format-of-time/ Share on other sites More sharing options...
Nicklas Posted December 19, 2006 Share Posted December 19, 2006 take a look at [url=http://www.php.net/strtotime]strtotime()[/url]ex[CODE]<?php$time = "12/19/06 04:27 am";echo strtotime($time);?>[/CODE] Link to comment https://forums.phpfreaks.com/topic/31237-chaging-the-format-of-time/#findComment-144485 Share on other sites More sharing options...
obsidian Posted December 19, 2006 Share Posted December 19, 2006 I believe strtotime() will handle that format:[code]<?php$ts = '12/19/06 04:27 am';echo strtotime($ts);?>[/code]*doh* -- beat me to it ;) Link to comment https://forums.phpfreaks.com/topic/31237-chaging-the-format-of-time/#findComment-144488 Share on other sites More sharing options...
ted_chou12 Posted December 19, 2006 Author Share Posted December 19, 2006 thanks :D Link to comment https://forums.phpfreaks.com/topic/31237-chaging-the-format-of-time/#findComment-144490 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.