Overwriting Date.php to output US Date format

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.2@59710 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Josh Kosmala 2008-08-04 04:47:56 +00:00 committed by Sam Minnee
parent 9aaa4064ae
commit a3274c9a31

View File

@ -33,6 +33,10 @@ class Date extends DBField {
if($this->value) return date('d/m/Y', strtotime($this->value)); if($this->value) return date('d/m/Y', strtotime($this->value));
} }
function NiceUS() {
if($this->value) return date('m/d/Y', strtotime($this->value));
}
/** /**
* Returns the year from the given date * Returns the year from the given date
*/ */