-
Bug
-
Resolution: Fixed
-
Minor
-
2.2.9, 2.3.6, 2.4.3
-
MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE
-
MOODLE_23_STABLE, MOODLE_24_STABLE
-
The magic in $mform->repeat_elements() does not allow for the developer to set a type on an element within a (named?) group.
The following code doesn't work:
$group = array(
|
$mform->createElement('text', 'repeatedgroupel1', 'repeatedgroupel1'),
|
$mform->createElement('text', 'repeatedgroupel2', 'repeatedgroupel2'));
|
$repeat = $mform->createElement('group', 'mygroup', 'mygroup', $group);
|
$this->repeat_elements(array($repeat), 2, array('mygroup[repeatedgroupel1]' => array('type' => PARAM_INT)),
|
'repeteablegroup', 'add', 0);
|
- will help resolve
-
MDL-39579 Tricky to set a type on elements within a named group inside repeated elements
- Closed