convert UK date to US date
<?php
/**
* private uk2usa()
* @param string $timestamp UK Date Format (d/m/Y)
* @return string American Date Format (Y-m-d)
*/
private function uk2usa($timestamp = FALSE)
{
if( ! $timestamp)
return date('Y-m-d');
list($day, $month, $year) = explode('/', $timestamp);
return $year . '-' . $month . '-' . $day;
}
// ------------------------------------------------------------------------