Die Klasse DateSelect erzeugt 3 Selectboxen zur Auswahl des Datums. Das aktuelle Datum ist hier vordefiniert.
include "DateSelect.php";
$ds = new DateSelect($name)
Create a new DateSelect object with the name $name as a prefix to the select box parameter name. The select boxes for day, month and year will named as {$name}_day, {$name}_month, {$name}_year.
$ds->day()
Returns the html code of a select box from 01 to 31 with the current day preselected.
ds->printDay()
Prints the html code of a select box from 01 to 31 with the current day preselected to STDOUT.
$ds->month()
Returns the html code of a select box from 01 to 12 with the current month preselected.
$ds->printMonth()
Prints the html code of a select box from 01 to 12 with the current month preselected to STDOUT.
$ds->year(<$range=2>)
Returns the html code of a select box from (current_year - $range) to (current year + $range) with the current year preselected. If $range not given, it will be set internally to 2.
$ds->printYear()
Prints the html code of a select box from (current_year - $range) to (current year + $range) with the current year preselected. If $range not given, it will be set internally to 2.
$ds->date()
Returns the html code of the three select boxes returned from day(), month() and year() with the current date preselected.
$ds->printDate()
Prints the html code of the three select boxes returned from day(), month() and year() with the current date preselected to STDOUT.
$ds->fetchDay()
Returns the value of the $name_day select box from the current request.
$ds->fetchMonth()
Returns the value of the $name_month select box from the current request.
$ds->fetchYear()
Returns the value of the $name_year select box from the current request.
$ds->fetchTimeStamp()
Fetches the values of the $name_day, $name_month, $name_year, select boxes from the current request. It returns a unix timestamp (sconds since the epoch) of the selected day at 00:00.