Skip to content

Commit

Permalink
MDL-34573 accessibility compliance for tag: Add forform input text an…
Browse files Browse the repository at this point in the history
…d select tag
  • Loading branch information
Rossiani Wijaya committed Sep 7, 2012
1 parent 555112a commit 5da3e35
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
11 changes: 7 additions & 4 deletions tag/coursetags_edit.php
Expand Up @@ -141,11 +141,12 @@
<div class="coursetag_edit_centered">
<div class="coursetag_edit_row">
<div class="coursetag_edit_left">
$edittagthisunit
<label for="coursetag_new_tag">$edittagthisunit</label>
</div>
<div class="coursetag_edit_right">
<div class="coursetag_form_input1">
<input type="text" name="coursetag_sug_keyword" class="coursetag_form_input1a" disabled="disabled" />
<label clas="accesshide" for="coursetag_sug_keyword">$edittagthisunit</label>
<input type="text" name="coursetag_sug_keyword" id="coursetag_sug_keyword" class="coursetag_form_input1a" disabled="disabled" />
</div>
<div class="coursetag_form_input2">
<input type="text" name="coursetag_new_tag" id="coursetag_new_tag" class="coursetag_form_input2a"
Expand All @@ -164,10 +165,12 @@
$outstr .= <<<EOT1
<div class="coursetag_edit_row">
<div class="coursetag_edit_left">
$editdeletemytag
<label for="del_tag">
$editdeletemytag
</label>
</div>
<div class="coursetag_edit_right">
<select name="del_tag">
<select id="del_tag" name="del_tag">
$selectoptions
</select>
</div>
Expand Down
7 changes: 5 additions & 2 deletions tag/manage.php
Expand Up @@ -260,8 +260,10 @@
$flag = $tag->flag;
$timemodified = format_time(time() - $tag->timemodified);
$checkbox = '<input type="checkbox" name="tagschecked[]" value="'.$tag->id.'" />';
$text = '<input type="text" name="newname['.$tag->id.']" />';
$tagtype = html_writer::select($existing_tagtypes, 'tagtypes['.$tag->id.']', $tag->tagtype, false);
$text = html_writer::label(get_string('newname', 'tag'), 'newname_' . $tag->id, false, array('class' => 'accesshide'));
$text .= '<input type="text" id="newname_' . $tag->id. '" name="newname['.$tag->id.']" />';
$tagtype = html_writer::label(get_string('tagtype', 'tag'), 'menutagtypes'. $tag->id, false, array('class' => 'accesshide'));
$tagtype .= html_writer::select($existing_tagtypes, 'tagtypes['.$tag->id.']', $tag->tagtype, false, array('id' => 'menutagtypes'. $tag->id));

//if the tag if flagged, highlight it
if ($tag->flag > 0) {
Expand All @@ -283,6 +285,7 @@
echo '<input type="button" onclick="checknone()" value="'.get_string('deselectall').'" /> ';
echo '<input type="hidden" name="sesskey" value="'.sesskey().'" /> ';
echo '<br/><br/>';
echo html_writer::label(get_string('withselectedtags', 'tag'), 'menuformaction', false, array('class' => 'accesshide'));
echo '<select id="menuformaction" name="action">
<option value="" selected="selected">'. get_string('withselectedtags', 'tag') .'</option>
<option value="reset">'. get_string('resetflag', 'tag') .'</option>
Expand Down

0 comments on commit 5da3e35

Please sign in to comment.