Hi,
I wonder if in Moodle 2.0, name and description of each role are going to be translated ?
Of course it is possible to change the name and desc. manually but I guess it is not a good practice.
Thanks.
In reply to Philip Siwinski
Re: Are roles name and description going to be translated ?
by Tim Hunt -
I think the roles are initially created with names in whatever language you choose during install.
There is no problem editing the names or descriptions of the standard roles. Just don't change the shortname - that is for internal use.
There is no problem editing the names or descriptions of the standard roles. Just don't change the shortname - that is for internal use.
In reply to Tim Hunt
Re: Are roles name and description going to be translated ?
by Philip Siwinski -
Currently, on 2.0, the roles are initially created in English.
Why do you recommend not to change shortnames when that possibility exists ?
Changing (translating) the shortnames, I discovered accentuated letters are replaced with non accentuated letters when saving the changes. I understand it is forbidden to use accentuated letters as shortnames are for internal use.
Why do you recommend not to change shortnames when that possibility exists ?
Changing (translating) the shortnames, I discovered accentuated letters are replaced with non accentuated letters when saving the changes. I understand it is forbidden to use accentuated letters as shortnames are for internal use.
In reply to Philip Siwinski
Re: Are roles name and description going to be translated ?
by Tim Hunt -
If there is no way to install Moodle 2.0 with French (for example) role names, then that is a bug. Please report it to the tracker.
Short names are for internal use. Although no core Moodle code relies on them (I think) a number of customisations do. And, you will sometimes see people exchanging useful database queries in these forums that include things like WHERE role.shortname = 'student'. Changing role shortnames would be a bit like wanting to change the mod/quiz/view.php bit of a Moodle URL.
Short names are for internal use. Although no core Moodle code relies on them (I think) a number of customisations do. And, you will sometimes see people exchanging useful database queries in these forums that include things like WHERE role.shortname = 'student'. Changing role shortnames would be a bit like wanting to change the mod/quiz/view.php bit of a Moodle URL.
Hmm, hardcoding of role names was a bad idea in the first place, we should have used lang pack strings instead.
I have already proposed a solution for this:
1/ keep the role->name empty by default
2/ if role->name empty use get_string('rolename_'.$role->shortname, 'role')
This way role default names would be properly localised.
I have already proposed a solution for this:
1/ keep the role->name empty by default
2/ if role->name empty use get_string('rolename_'.$role->shortname, 'role')
This way role default names would be properly localised.
In reply to Petr Skoda
Re: Are roles name and description going to be translated ?
by Nicolas Martignoni -
+1 Petr. The current behaviour has caused confusion more than once in non-english environments, and your proposal would solve this.
In reply to Tim Hunt
Re: Are roles name and description going to be translated ?
by Nicolas Martignoni -
As a matter of fact, there is a bug in Moodle 2.0 PR4 when installing Moodle in other languages: MDL-22657.
In reply to Nicolas Martignoni
Re: Are roles name and description going to be translated ?
by Nicolas Martignoni -
Petr just fixed MDL-22657, so the installation works in other languages and the role names are adequately set in your language.
Thanks to him
In reply to Nicolas Martignoni
Re: Are roles name and description going to be translated ?
by Andrea Bicciolo -
Hi,
just reopened the bug as the CLi installer seems to be fixed to support Petr changes.
just reopened the bug as the CLi installer seems to be fixed to support Petr changes.