Hashes::createOptions

Usage

string Hashes::createOptions(string $hash_alias, [ array | string $value = '' ], [ string $form_field = 'select' ], [ string $form_name = '' ])

Description

Generate HTML code for a list of select / radio / checkbox options using one of multiple sources.

Parameters

Parameter Required Type Description
$hash_alias Yes string The alias of the hash to use, formatted as PACKAGE.ALIAS
$value No array | string The selected value of the list
$form_field No string The type of HTML to generate. Can be either: select, radio, checkbox
$form_name No string Only required for radio or checkbox lists and is the form name

Return Value

HTML code of the generated option list

See Also