Must custom list.php files reside in every /lang/xx_utf8 folder?

Must custom list.php files reside in every /lang/xx_utf8 folder?

by Worth Bishop -
Number of replies: 2
We're running 1.6.1+ (downloaded 7/29/06) and have converted data to UTF8.

We long ago added a "State" variable to our Moodle db and created a states.php file of strings listing all US states & possesions so users could select their state from a list when registering.

After upgrading to 1.6.1+ and migrating data to UTF-8, we added the en_us_utf8 language pack, which now resides in /moodledata/lang/en_us_utf8.

We copied the states.php file to /moodle/lang/en_utf8/. As long as a user's language preference is English (en) the states list displays normally in the customized registration and user edit pages. If a user's language preference is set to English (en_us) the states list does not display. (We converted states.php to UTF-8 using iconv - same result.)

We then copied the states.php file into the /moodle/lang/en_us_utf8/ directory, but  had the same issue, the list did not display. How can we make this list available in every language preference?

In previous Moodle versions, placing the states.php file in only moodle/lang/en/ was sufficient as other languages defaulted to this directory and picked up the strings in this file as a default.

Thanks for any help!

Average of ratings: -
In reply to Worth Bishop

Re: Must custom list.php files reside in every /lang/xx_utf8 folder?

by koen roggemans -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Translators
I just tried this with a module form contrib and it works as expected: a language file in moodle/lang/en_utf8 is used as fall back for all other languages.

My only wild guess is that there's "something wrong" with the way you retreive the list from the language packs
In reply to koen roggemans

Re: Must custom list.php files reside in every /lang/xx_utf8 folder?

by Worth Bishop -
Thanks, I'll double check and report.