Reputation: 1852
I want to change the time format using php but I can not get it right.
The loaded value (delivery_eta)
got the time format Ymd
, so for example 20180925
.
But I want to change that to Tuesday 25 September 2018.
My current code:
<?php $locale = 'nl_NL'; $date = new Zend_Date($_product->getData('delivery_eta'),'Ymd'); $date->setLocale($locale);echo $date->toString(Zend_Date::DATE_FULL);?>
No the output is:
Sunday 9 January 20
What am I missing?
Upvotes: 0
Views: 53