code_junkie

What's the best way to manage dates across PHP, MySQL, etc?

Nov 13th, 2011
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.15 KB | None | 0 0
  1. UNIX_TIMESTAMP(date)
  2. FROM_UNIXTIME(unix_timestamp)
  3.  
  4. mysql_query('SET time_zone = "'.$timezone.'"');
  5.  
  6. date_default_timezone_set($timezone);
Add Comment
Please, Sign In to add comment