API16:JForm/addFields
From Joomla! Documentation
Contents |
Description
Method to add an array of fields to a group.
Syntax
addFields(&$fields, $group= '_default')
| Parameter Name | Default Value | Description |
|---|---|---|
| &$fields | $fields An array of field objects to add. | |
| $group | '_default' | $group The group to add the fields to. |
Returns
void
Defined in
libraries/joomla/form/form.php
Importing
jimport( 'joomla.form.form' );
Source Body
public function addFields(&$fields, $group = '_default') { // Add the fields to the group. foreach ($fields as $field) { $this->_groups[$group][(string)$field->attributes()->name] = $field; } }
[Edit See Also] SeeAlso:JForm/addFields