loony383 Posted June 4, 2008 Share Posted June 4, 2008 how do i display a date and time from a timestamp $frm3[post_time] is a timestamp how could i set a varible to the date and time using the timestamp? Link to comment https://forums.phpfreaks.com/topic/108760-displaying-a-date-and-time-from-a-timestamp/ Share on other sites More sharing options...
revraz Posted June 4, 2008 Share Posted June 4, 2008 What kind of timestamp, Unix or MySQL? Link to comment https://forums.phpfreaks.com/topic/108760-displaying-a-date-and-time-from-a-timestamp/#findComment-557891 Share on other sites More sharing options...
loony383 Posted June 4, 2008 Author Share Posted June 4, 2008 Mysql Link to comment https://forums.phpfreaks.com/topic/108760-displaying-a-date-and-time-from-a-timestamp/#findComment-557901 Share on other sites More sharing options...
discomatt Posted June 4, 2008 Share Posted June 4, 2008 so assuming YYYY-MM-DD HH:MM:SS You can use the mysql function UNIX_TIMESTAMP Link to comment https://forums.phpfreaks.com/topic/108760-displaying-a-date-and-time-from-a-timestamp/#findComment-557906 Share on other sites More sharing options...
loony383 Posted June 4, 2008 Author Share Posted June 4, 2008 Im no good at php anymore becuase i stopped for such a long time so how would i use that in my code? i just need a way to change things like 1210198018 into an understandable/readable date and time. Link to comment https://forums.phpfreaks.com/topic/108760-displaying-a-date-and-time-from-a-timestamp/#findComment-557911 Share on other sites More sharing options...
discomatt Posted June 4, 2008 Share Posted June 4, 2008 That's a unix timestamp. Check out the date() function. Link to comment https://forums.phpfreaks.com/topic/108760-displaying-a-date-and-time-from-a-timestamp/#findComment-557913 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.