JDate
Description
JDate is a class that stores a date
Located in /joomla/utilities/date.php (line 25)
JObject (Subpackage Base)
![]()
JDate (Subpackage Utilities)
Method Summary
Variables
int|boolean
$_date
= false (line 33)
Unix timestamp
string
$_offset
= 0 (line 41)
Time offset (in seconds)
Inherited Variables
Inherited from JObject
JObject::$_errors
Methods
Creates a new instance of JDate representing a given date.
Accepts RFC 822, ISO 8601 date formats as well as unix time stamps. If not specified, the current date and time is used.
JDate
__construct
([mixed $date = 'now'], int $tzOffset)
- mixed $date: optional the date this JDate will represent.
- int $tzOffset: optional the timezone $date is from
Redefinition of:
- JObject::__construct()
- Class constructor, overridden in descendant classes.
Set the date offset (in hours)
void
setOffset
(float $offset)
- float $offset: The offset in hours
Gets the date in a specific format
Returns a string formatted according to the given format. Month and weekday names and other language dependent strings respect the current locale
a
toFormat
([string $format = '%Y-%m-%d %H:%M:%S'])
- string $format: The date format specification string (see http://www.php.net/strftime)
Translates day of week number to string
string
_dayToString
(int $day, [bool $abbr = false])
- int $day: The numeric day of the week
- bool $abbr: Return the abreviated day string?
Translates month number to string
string
_monthToString
(int $month, [bool $abbr = false])
- int $month: The numeric month of the year
- bool $abbr: Return the abreviated month string?
Translates needed strings in for JDate::toFormat (see http://www.php.net/strftime)
string
_strftime
(string $format, int $time)
- string $format: The date format specification string (see http://www.php.net/strftime)
- int $time: Unix timestamp
Inherited Methods
Inherited From JObject
JObject::JObject()
JObject::__construct()
JObject::get()
JObject::getError()
JObject::getErrors()
JObject::getProperties()
JObject::getPublicProperties()
JObject::set()
JObject::setError()
JObject::setProperties()
JObject::toString()
Documentation generated on Sat, 14 Nov 2009 11:12:08 +0000 by phpDocumentor 1.3.1



