Date Format Conversion In PHP

Common date formats in PHP are m/d/y and d-m-y.
If the separator is a forward slash (/), then PHP assumes it as American format whereas, if the separator
is hyphen (-) or a Dot (.), then assumes it as European format.
To avoid this ambiguity, it is considered best to user DateTime::createFromFormat(). It works in almost all the cases.
Example:-

$cal_date = "20/04/2014";
echo date('Y-m-d', strtotime($cal_date)); // 1969-12-31
echo "###################";
$date = DateTime::createFromFormat('d/m/Y',$cal_date);
$invdate = $date->format('Y-m-d'); 
echo $invdate; //  2014-04-20
For more details regarding the date formats you may visit PHP official website:
date formats