Methods summary
public
|
#
init( integer $start_year = '', integer $end_year = '', boolean $picker = true, integer $format_in = null, integer $format_out = '%x' )
Return the date supplied as a Horde_Date object.
Return the date supplied as a Horde_Date object.
Parameters
- $start_year
- The first available year for input.
- $end_year
- The last available year for input.
- $picker
- Do we show the DHTML calendar?
- $format_in
- <p>The format to use when sending the date
for storage. Defaults to Unix epoch.
Similar to the strftime() function.</p>
- $format_out
- <p>The format to use when displaying the
date. Similar to the strftime() function.</p>
Overrides
|
public
|
#
isValid( mixed & $var, mixed & $vars, mixed $value, mixed & $message )
|
public
integer
|
#
emptyDateArray( mixed $date )
Determine if the provided date value is completely empty, partially empty
or non-empty.
Determine if the provided date value is completely empty, partially empty
or non-empty.
Parameters
- $date
- String or date part array representation of date.
Returns
integer 0 for non-empty, 1 for completely empty or -1 for
partially empty.
|
public
array
|
#
getDateParts( string $date_in )
Return the date supplied split up into an array.
Return the date supplied split up into an array.
Parameters
- $date_in
- <p>Date in one of the three formats supported by
Horde_Form and Horde_Date (ISO format
YYYY-MM-DD HH:MM:SS, timestamp YYYYMMDDHHMMSS
and UNIX epoch) plus the fourth YYYY-MM-DD.</p>
Returns
array Array with three elements - year, month and day.
|
public
Horde_Date
|
#
getDateOb( string $date_in )
Return the date supplied as a Horde_Date object.
Return the date supplied as a Horde_Date object.
Parameters
- $date_in
- <p>Date in one of the three formats supported by
Horde_Form and Horde_Date (ISO format
YYYY-MM-DD HH:MM:SS, timestamp YYYYMMDDHHMMSS
and UNIX epoch) plus the fourth YYYY-MM-DD.</p>
Returns
Horde_Date The date object.
|
public
string
|
#
formatDate( string $date )
Return the date supplied as a Horde_Date object.
Return the date supplied as a Horde_Date object.
Parameters
- $date
- <p>Either an already set up Horde_Date object or a
string date in one of the three formats supported
by Horde_Form and Horde_Date (ISO format
YYYY-MM-DD HH:MM:SS, timestamp YYYYMMDDHHMMSS and
UNIX epoch) plus the fourth YYYY-MM-DD.</p>
Returns
string The date formatted according to the $format_out
parameter when setting up the monthdayyear field.
|
public
|
#
getInfo( mixed & $vars, mixed & $var, mixed & $info )
Insert the date input through the form into $info array, in the format
specified by the $format_in parameter when setting up monthdayyear
field.
Insert the date input through the form into $info array, in the format
specified by the $format_in parameter when setting up monthdayyear
field.
Overrides
|
public
|
#
_validateAndFormat( mixed $value, mixed & $var )
Validate/format a date submission.
Validate/format a date submission.
|
public
|
#
about( )
Return info about field type.
Return info about field type.
|