On Wed, Oct 28, 2009 at 2:29 PM, Shaun Farrell <farrel...@gmail.com> wrote:
> Peter, > > Try this. It may work > > $indate = "Fri Oct 23 15:47:42 +0000 2009"; > $outformat = "EEEE d MMM YYYY"; > $date = new Zend_Date(); > $date->setTimezone('Europe/Helsinki'); > $datetime = strtotime($indate); > $date->set($datetime); > > echo "Date: " . $date->toString($outformat); > echo "TimeZone: " . $date->getTimezone(); > > > It works, it is indeed a workaround to convert the date to a timestamp with strtotime and construct a date from that. I have only the following 2 concerns - I was expecting Zend_Date to do this for me, so is my expectation wrong than this is a solution, if not it's a workaround - This will not work with dates outside the range of the timestamp (> year 2039 according to http://php.net/manual/en/function.strtotime.php#function.strtotime.notes)