Details
-
Type:
Improvement
-
Status: Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 2.0.3, 2.1, 2.2
-
Fix Version/s: 2.1.1
-
Labels:
-
Testing Instructions:
-
Difficulty:Moderate
-
Affected Branches:MOODLE_20_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE
-
Fixed Branches:MOODLE_21_STABLE
-
Pull from Repository:
-
Pull Master Branch:glossary_multilang_master
-
Pull Master Diff URL:
Description
Using "FAQ" in glossary module, the new created categories cannot be displayed correctly in multiple languages using multilang filter. (<span class="multilang" lang="en">...</span> ....)
In the heading, it shows the hole code.
In the drop-down box, it shows all languages one after another (but without code).
####################
UPDATE (28 June 11):
####################
Screenshot 1: Shows the category drop-down-box on the right with both languages one after another; in addition, you can see the chosen category in the middle showing the hole code. To fix both of these bugs, add some "format_string()" to /mod/glossary/lib.php
line 1675: $menu[$url] = clean_text(format_string($currentcategory->name));
line 1683: echo format_text(format_string($category->name), FORMAT_PLAIN);
(Attention: These lines are refering to the glossary module version 2010111501. In older or newer versions, the lines may differ!)
Screenshot 2: When editing categories, the overview shows the hole multilang code. In addition, if you try to delete a category, the confirmation page also shows the hole code. Both bugs can also be fixed with some format_string() calls added to /mod/glossary/editcategories.php
line 218: echo "<span class=\"bold\">".format_text(format_string($category->name), FORMAT_PLAIN)."</span> <span>($num_entries " . get_string("entries","glossary") . ")</span>";
line 121: echo "<div class=\"boxaligncenter deletecatconfirm\">".format_text(format_string($category->name), FORMAT_PLAIN)."<br/>";
(Attention: These lines are refering to the glossary module version 2010111501. In older or newer versions, the lines may differ!)
Screenshot 3: The category headings also show all languages one after another. I didn't find a fix for that until now.