Function __global->form_input_date__cron
Definitions
sources/form_templates.php
- Get the Tempcode for a date input, or if the system scheduler is not running return blank.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: object
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $pretty_name | mixed | No | No | required parameter | N/A | N/A | A human intelligible name for this input field, provided in plain-text format (string or Tempcode) |
| $description | mixed | No | No | required parameter | N/A | N/A | A description for this input field, provided in HTML format (string or Tempcode) |
| $name | ID_TEXT | No | No | required parameter | N/A | N/A | The parameter name for this input field |
| $required | boolean | No | No | required parameter | N/A | N/A | Whether this is a required field |
| $null_default | boolean | No | No | required parameter | N/A | N/A | Whether this field is empty by default |
| $do_time | boolean | No | No | required parameter | N/A | N/A | Whether to input time for this field also |
| $default_time | ?mixed | No | No | Null | N/A | N/A | The default timestamp to use (either TIME or array of time components) (null: none) [ignored if $null_default is set] |
| $total_years_to_show | ?integer | No | No | 10 | N/A | N/A | The number of years to allow selection from (pass a negative number for selection of past years instead of future years) (null: no limit) |
| $year_start | ?integer | No | No | Null | N/A | N/A | The year to start counting $total_years_to_show from (null: if $total_years_to_show<0 then this year minus $total_years_to_show else if $total_years_to_show is not null then the current year else no restriction) |
| $tabindex | ?integer | No | No | Null | N/A | N/A | The tab index of the field (null: not specified) |
Returns
- The input field
- Type: Tempcode
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Get the Tempcode for a date input, or if the system scheduler is not running return blank.
*
* @param mixed $pretty_name A human intelligible name for this input field, provided in plain-text format (string or Tempcode)
* @param mixed $description A description for this input field, provided in HTML format (string or Tempcode)
* @param ID_TEXT $name The parameter name for this input field
* @param boolean $required Whether this is a required field
* @param boolean $null_default Whether this field is empty by default
* @param boolean $do_time Whether to input time for this field also
* @param ?mixed $default_time The default timestamp to use (either TIME or array of time components) (null: none) [ignored if $null_default is set]
* @param ?integer $total_years_to_show The number of years to allow selection from (pass a negative number for selection of past years instead of future years) (null: no limit)
* @param ?integer $year_start The year to start counting $total_years_to_show from (null: if $total_years_to_show<0 then this year minus $total_years_to_show else if $total_years_to_show is not null then the current year else no restriction)
* @param ?integer $tabindex The tab index of the field (null: not specified)
* @return Tempcode The input field
*/
function form_input_date__cron($pretty_name, $description, string $name, bool $required, bool $null_default, bool $do_time, $default_time = null, ?int $total_years_to_show = 10, ?int $year_start = null, ?int $tabindex = null) : object
* Get the Tempcode for a date input, or if the system scheduler is not running return blank.
*
* @param mixed $pretty_name A human intelligible name for this input field, provided in plain-text format (string or Tempcode)
* @param mixed $description A description for this input field, provided in HTML format (string or Tempcode)
* @param ID_TEXT $name The parameter name for this input field
* @param boolean $required Whether this is a required field
* @param boolean $null_default Whether this field is empty by default
* @param boolean $do_time Whether to input time for this field also
* @param ?mixed $default_time The default timestamp to use (either TIME or array of time components) (null: none) [ignored if $null_default is set]
* @param ?integer $total_years_to_show The number of years to allow selection from (pass a negative number for selection of past years instead of future years) (null: no limit)
* @param ?integer $year_start The year to start counting $total_years_to_show from (null: if $total_years_to_show<0 then this year minus $total_years_to_show else if $total_years_to_show is not null then the current year else no restriction)
* @param ?integer $tabindex The tab index of the field (null: not specified)
* @return Tempcode The input field
*/
function form_input_date__cron($pretty_name, $description, string $name, bool $required, bool $null_default, bool $do_time, $default_time = null, ?int $total_years_to_show = 10, ?int $year_start = null, ?int $tabindex = null) : object

