span class="multilang" lang="XY" isn't working in Navigation Menu?

Re: span class="multilang" lang="XY" isn't working in Navigation Menu?

by Joseph Rézeau -
Number of replies: 0
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Resurrecting this old thread because we were asked a related question on the French forum recently.

Using Moodle 2.5. Here are my findings.

1.- A multilang filter takes a minimum of 41 characters: <span class="multilang" lang="en"></span>

2.- Course full name field is limited to 255 characters. The following are some possible combinations of number or languages and length of full course names:

  • 2 different languages with a total of 255 - (41 * 2) = 173 characters, or about 86 characters each;
  • 3 different languages with a total of 255 - (41 * 3) = 134 characters, or about 44 characters each;
  • 4 different languages with a total of 255 - (41 * 4) = 91 characters, or about 22 characters each;
  • etc.

3.- Course short name field is limited to 100 characters. The only possibility for 2 different languages is a total of 100 - (41 * 2) = 19 characters, so about 9 characters each!

Conclusion: Course short names are really not suited for multilang names. In Moodle "short course name" really means "abbreviated" name, such as MATHS-02-B-YR01 and the like. With that consideration in mind, should we accept the 100 characters limitation which actually prevents course short names from being a) meanginful and b) available in more than one language, like the course full names are?

Or should we ask the Moodle core developers to extend that 100 chars limit to 255? That is in file course/edit_form line 50 (in moodle 2.5):

$mform->addElement('text', 'shortname', get_string('shortnamecourse'), 'maxlength="100" size="20"');

See MDL-29189. Does this warrant opening a new issue in the tracker? What do you think?

Joseph

Average of ratings: Useful (3)