Back to Date class

Method __toString

public string
__toString
()
Magic method to render the date object in the format specified in the public static member Date::$format.
Returns
  • string The date as a formatted string.
Since
  • 1.7.0
Class: Date
Project: Joomla

Method __toString - Source code

/**
 * Magic method to render the date object in the format specified in the public
 * static member Date::$format.
 *
 * @return  string  The date as a formatted string.
 *
 * @since   1.7.0
 */
public function __toString()
{
    return (string) parent::format(self::$format);
}