public function toAtom($dateString, $timezone = null)
    {
        $timezone = $this->_getTimezone($timezone) ?: date_default_timezone_get();

        return (new Time($dateString))->timezone($timezone)->toAtomString();
    }
public function toAtom($dateString, $timezone = null)
    {
        $timezone = $this->_getTimezone($timezone) ?: date_default_timezone_get();

        return (new Time($dateString))->timezone($timezone)->toAtomString();
    }
public function toAtom ( $ dateString , $ timezone = null ) { $ timezone = $ this -> _getTimezone ( $ timezone ) ? : date_default_timezone_get ( ) ; return ( new Time ( $ dateString ) ) -> timezone ( $ timezone ) -> toAtomString ( ) ; }
Returns a date formatted for Atom RSS feeds.

@param int|string|\DateTime $dateString UNIX timestamp, strtotime() valid string or DateTime object
@param string|\DateTimeZone|null $timezone User's timezone string or DateTimeZone object
@return string Formatted date string
@see \Cake\I18n\Time::toAtom()
Returns a date formatted for Atom RSS feeds .