I have the html form which enter data into mysql DB, but in input field of date it has this format,
(mm/dd/yyyy)
BUT I prefer to use this form
use this code
$originalDate = "2010-03-21"; $newDate = date("d-m-Y", strtotime($originalDate));