| Recommend this page to a friend! |
| Packages of Michael Beck | Xoops 2.5 | htdocs/xoops_lib/vendor/smarty/smarty/docs/designers/language-custom-functions/language-function-html-checkboxes.md | Download |
|
|||||||||||||||||||||
{html_checkboxes}
Attributes| Attribute Name | Required | Description | |----------------|-------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | name | No | Name of checkbox list (defaults to 'checkbox') | | values | Yes, unless using options attribute | An array of values for checkbox buttons | | output | Yes, unless using options attribute | An array of output for checkbox buttons | | selected | No | The selected checkbox element(s) as a string or array | | options | Yes, unless using values and output | An associative array of values and output | | separator | No | String of text to separate each checkbox item | | assign | No | Assign checkbox tags to an array instead of output | | labels | No | Add <label\>-tags to the output (defaults to true) | | label\_ids | No | Add id-attributes to <label\> and <input\> to the output (defaults to false) | | escape | No | Escape the output / content (values are always escaped) (defaults to true) | | strict | No | Will make the "extra" attributes disabled and readonly only be set, if they were supplied with either boolean TRUE or string "disabled" and "readonly" respectively (defaults to false) |
Examples
where template is
or where PHP code is:
and the template is
both examples will output:
The results of the database queries above would be output with.
See also |