|
|
|
Issue Links:
|
Dependency
|
|
This issue will help resolve:
|
|
|
MDL-17064 Allow user to enter the required quantity of repeated elements in one page reload
|
|
|
|
|
|
|
|
| Participants: |
Jamie Pratt and Oleg Sychev
|
| Security Level: |
None
|
| Difficulty: |
Easy
|
| Affected Branches: |
MOODLE_19_STABLE
|
|
Improving usability of question editing I found that code below result in error:
$mform->addElement('text',$repeatname,$repeatstring,array('size'=>3));
$mform->addElement('hidden', $repeathiddenname, $repeats);
$mform->addRule($repeatname,null,'required',null,'client',true);
$mform->addRule($repeatname,null,'nonzero',null,'client',true);
//$mform->addRule(array($repeatname, $repeathiddenname),'You can\'t delete blanks','compare','>=','client',true);//uncommenting this line results in error in getValidationScript
If you uncomment the last line you receive
"Fatal error: Call to a member function on a non-object in z:\home\moodle\www\lib\formslib.php"
The line with error is "$onBlur = $element->getAttribute('onBlur');" in function getValidationScript
|
|
Description
|
Improving usability of question editing I found that code below result in error:
$mform->addElement('text',$repeatname,$repeatstring,array('size'=>3));
$mform->addElement('hidden', $repeathiddenname, $repeats);
$mform->addRule($repeatname,null,'required',null,'client',true);
$mform->addRule($repeatname,null,'nonzero',null,'client',true);
//$mform->addRule(array($repeatname, $repeathiddenname),'You can\'t delete blanks','compare','>=','client',true);//uncommenting this line results in error in getValidationScript
If you uncomment the last line you receive
"Fatal error: Call to a member function on a non-object in z:\home\moodle\www\lib\formslib.php"
The line with error is "$onBlur = $element->getAttribute('onBlur');" in function getValidationScript |
Show » |
made changes - 03/Nov/08 08:49 PM
| Field |
Original Value |
New Value |
|
Link
|
|
This issue will help resolve MDL-17064
[ MDL-17064
]
|
made changes - 05/Nov/08 02:38 AM
|
Difficulty
|
Moderate
|
Easy
|
|
Summary
|
Using compare rule on hidden and no hidden elements results in fatal error in getValidationScript function
|
Using compare rule results in fatal error in getValidationScript function
|
|