Skip to content

Commit

Permalink
MDL-19809 Upgraded calls to choose_from_menu
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolasconnault committed Aug 18, 2009
1 parent b46eec3 commit 34c2868
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion mod/glossary/formats.php
Expand Up @@ -77,7 +77,7 @@
//Sort it
asort($formats);

choose_from_menu($formats,'popupformatname',$displayformat->popupformatname);
echo $OUTPUT->select(html_select::make($formats,'popupformatname',$displayformat->popupformatname));
?>
</td>
<td width="60%">
Expand Down
6 changes: 4 additions & 2 deletions mod/glossary/lib.php
Expand Up @@ -2299,7 +2299,7 @@ function glossary_get_ratings_summary($entryid, $scale, $ratings=NULL) {
* @param array $scale
*/
function glossary_print_rating_menu($entryid, $userid, $scale) {
global $DB;
global $DB, $OUTPUT;

static $strrate;

Expand All @@ -2310,8 +2310,10 @@ function glossary_print_rating_menu($entryid, $userid, $scale) {
if (empty($strrate)) {
$strrate = get_string("rate", "glossary");
}
$select = html_select::make($scale, $entryid, $rating->rating, "$strrate...");
$select->nothingvalue = '-999';

choose_from_menu($scale, $entryid, $rating->rating, "$strrate...",'',-999);
echo $OUTPUT->select($select);
}

/**
Expand Down

0 comments on commit 34c2868

Please sign in to comment.