Posted By

isaac on 04/15/08


Tagged

php date format to usa transform reverse easy d-m-y y-m-d european quickest


Versions (?)

Who likes this?

7 people have marked this snippet as a favorite

luman
heinz1959
pagetoscreen
pixelhandler
neverwolf
Hollow
ninjacharlee


Easy transform date format y-m-d => d-m-y on PHP


 / Published in: PHP
 

URL: http://www.php.net/manual/es/function.date.php#81946

This changes the date format from y-m-d to d-m-y on PHP

  1. //This code is extracted from the comments on the php.net docs
  2. // Quickest: Y-m-d => Brittish Format
  3. print date("d.m.Y",strtotime("2008-01-01"));
  4.  
  5. //Will return: 01.01.2008.

Report this snippet  

You need to login to post a comment.