class JFormFieldCheckboxes extends JFormFieldList

Form Field class for the Joomla Platform.

Displays options as a list of checkboxes. Multiselect may be forced to be true.

Properties

mixed $checkedOptions The comma seprated list of checked checkboxes value.

Methods

addOption( string $text, array $attributes = array())

Method to add an option to the list field.

mixed
__get( string $name)

Method to get certain otherwise inaccessible properties from the form field object.

void
__set( string $name, mixed $value)

Method to set certain otherwise inaccessible properties of the form field object.

boolean
setup( SimpleXMLElement $element, mixed $value, string $group = null)

Method to attach a JForm object to the field.

Details

JFormFieldList addOption( string $text, array $attributes = array())

Method to add an option to the list field.

Parameters

string $text Text/Language variable of the option.
array $attributes Array of attributes ('name' => 'value' format)

Return Value

JFormFieldList For chaining.

mixed __get( string $name)

Method to get certain otherwise inaccessible properties from the form field object.

Parameters

string $name The property name for which to get the value.

Return Value

mixed The property value or null.

void __set( string $name, mixed $value)

Method to set certain otherwise inaccessible properties of the form field object.

Parameters

string $name The property name for which to set the value.
mixed $value The value of the property.

Return Value

void

boolean setup( SimpleXMLElement $element, mixed $value, string $group = null)

Method to attach a JForm object to the field.

Parameters

SimpleXMLElement $element The SimpleXMLElement object representing the <field> tag for the form field object.
mixed $value The form field value to validate.
string $group The field name group control value. This acts as an array container for the field. For example if the field has name="foo" and the group value is set to "bar" then the full field name would end up being "bar[foo]".

Return Value

boolean True on success.

See also

JFormField::setup()