mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 17:36:38 +02:00
MDL-13766, added hidden elements to make label 'for' attribute happly
This commit is contained in:
parent
dcf9be7f56
commit
ce47962ed5
2 changed files with 4 additions and 0 deletions
|
@ -152,6 +152,8 @@ class MoodleQuickForm_filemanager extends HTML_QuickForm_element {
|
|||
$html .= $OUTPUT->file_manager($options);
|
||||
|
||||
$html .= '<input value="'.$draftitemid.'" name="'.$elname.'" type="hidden" />';
|
||||
// label element needs 'for' attribute work
|
||||
$html .= '<input value="" id="id_'.$elname.'" type="hidden" />';
|
||||
|
||||
return $html;
|
||||
}
|
||||
|
|
|
@ -82,6 +82,8 @@ class MoodleQuickForm_filepicker extends HTML_QuickForm_input {
|
|||
$options = $fp->options;
|
||||
$str .= $OUTPUT->render($fp);
|
||||
$str .= '<input type="hidden" name="'.$elname.'" id="'.$id.'" value="'.$draftitemid.'" />';
|
||||
// label element needs 'for' attribute work
|
||||
$html .= '<input value="" id="id_'.$elname.'" type="hidden" />';
|
||||
return $str;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue