Function __global->form_input_tree_list

Definitions

sources/form_templates.php

  • Get the Tempcode for an AJAX-powered tree listbox.
  • 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 name which this input field is for
$root_id ?ID_TEXT No No required parameter N/A N/A The ID to do under (null: root)
$hook string No No required parameter N/A N/A The ajax tree-list hook that drives our data
$options array No No required parameter N/A N/A A map of special options
$required boolean No No required parameter N/A N/A Whether this is a required input field
$default ?string No No Null N/A N/A The default value for the field (null: none)
$use_server_id boolean No No False N/A N/A Whether to use the server-ID in the list instead of the ID in the list
$tabindex ?integer No No Null N/A N/A The tab index of the field (null: not specified)
$multi_select boolean No No False N/A N/A Whether multiple selections are allowed
$nice_label ?string No No Null N/A N/A Label for default value (null: just use the literal)

Returns

  • The input field
  • Type: Tempcode
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Get the Tempcode for an AJAX-powered tree listbox.
 *
 * @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 name which this input field is for
 * @param  ?ID_TEXT $root_id The ID to do under (null: root)
 * @param  string $hook The ajax tree-list hook that drives our data
 * @param  array $options A map of special options
 * @param  boolean $required Whether this is a required input field
 * @param  ?string $default The default value for the field (null: none)
 * @param  boolean $use_server_id Whether to use the server-ID in the list instead of the ID in the list
 * @param  ?integer $tabindex The tab index of the field (null: not specified)
 * @param  boolean $multi_select Whether multiple selections are allowed
 * @param  ?string $nice_label Label for default value (null: just use the literal)
 * @return Tempcode The input field
 */

function form_input_tree_list($pretty_name, $description, string $name, ?string $root_id, string $hook, array $options, bool $required, ?string $default = null, bool $use_server_id = false, ?int $tabindex = null, bool $multi_select = false, ?string $nice_label = null) : object