Possible Duplicate:
PHP: convert date format yyyy-mm-dd => dd-mm-yyyy [NOT IN SQL]
Right now I have DATE stored in mysql as : YY-MM-DD. EX: 2011-12-22
.
How can I convert using strtotime to MM-DD-YY in php?
Possible Duplicate:
PHP: convert date format yyyy-mm-dd => dd-mm-yyyy [NOT IN SQL]
Right now I have DATE stored in mysql as : YY-MM-DD. EX: 2011-12-22
.
How can I convert using strtotime to MM-DD-YY in php?
$originalDate = "2010-03-21";
$newDate = date("d-m-Y", strtotime($originalDate));
or use the following link for the similar question Convert date format yyyy-mm-dd => dd-mm-yyyy