Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-71594

In user/editlib.php, get_string('selectacountry') should ideally be get_string('country')

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.9.7, 3.10.4, 3.11
    • Fix Version/s: None
    • Component/s: User management
    • Labels:
    • Affected Branches:
      MOODLE_310_STABLE, MOODLE_311_STABLE, MOODLE_39_STABLE

      Description

      In login/signup_form.php (which produces the user registration page), the following line appears:

      $mform->addElement('select', 'country', get_string('country'), $country);

      The text string for 'country' is, simply, Country. An admin who wants to clarify what 'Country' means (eg, country of residence or citizenship?) can use Language Customisation to change the 'country' string.

      However, in user/editlib.php (which produces the edit profile page), the get_string element contains 'selectacountry' instead of 'country':

      $mform->addElement('select', 'country', get_string('selectacountry'), $choices, $purpose);

      So any Language Customisation made to the 'country' string will not be reflected in the edit profile form, which will continue to have the string for 'selectacountry', which is 'Select a country'.

      I think the get_string() element should be consistent in signup_form.php and editlib.php, so I'd like to suggest that the above line in user/editlib.php be changed to:

      $mform->addElement('select', 'country', get_string('country'), $choices, $purpose);

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            ravim Ravi Murugesan
            Participants:
            Component watchers:
            Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona)
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated: