SproutCMS

This is the code documentation for the SproutCMS project

function checkboxList()

Outputs a list of checkboxes.

If the $field parameter is provided, multiple checkboxes with the same field name will be rendered.
   $data should be a key-value pair, with the keys being the value of the checkbox, and the value being the label.
   $selected should be an array of selected checkbox ids.

If the $field parameter is omitted (null), multiple checkboxes widh different field names will be rendered.
The checkboxes will be binary checkboxes with a value of 1.
   $data should be a key-value pair, with the keys being the field name, and the value being the label.
   $selected should be a key-value pair, with the keys being the field name, and the value being 1 or 0.

Usage

void Admin::checkboxList ( mixed $field , mixed $data , mixed $selected );

Arguments

  1. $field
  2. $data
  3. $selected

Return value

  • void