Skip to content

Instantly share code, notes, and snippets.

@hamaguchi
Created January 21, 2015 09:19
Show Gist options
  • Save hamaguchi/aa161f0682eced3560cb to your computer and use it in GitHub Desktop.
Save hamaguchi/aa161f0682eced3560cb to your computer and use it in GitHub Desktop.
MySQL Date
// $date = "Tue, 20 Jan 2015 12:20:53 +0900"
// $sdate = "2013-08-25T17:00:00+00:00"
$tpdate = new DateTime($date);
$sdate = $tpdate->format('Y-m-d\TH:i:s');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment