Enonic version: 6.15.2
I have some questions related to localization and fallback, for version 6.15.2
I found that for a new Danish subsite, the site did not pick up the new properties file automatically. That was mystifying, but then I discovered that there were at last two variants to choose from for all languages. This makes sense for languages with two or more variants, like Norwegian, but seems unnecessary for Danish, which to my knowledge has only one. However, it did not work regardless.
The customer had used the setting ‘Dansk (Danmark) (da-DK)’ instead of ‘Dansk (da)’, so my phrases_da.properties was not picked up. Renaming the file to danish_da_dk.properties had no effect, I even tried with dk in uppercase (contrary to the documentation), but to no avail. Not until I changed the language to ‘Dansk (da)’ instead of ‘Dansk (Danmark) (da-DK)’ did the site pick up the language variables. But then it worked, reading from the file phrases_da.properties. The other file, phrases_da_dk.properties was never read.
I found this a bit strange, shouldn’t the site pick up my phrases_da_dk.properties file for the ‘Dansk (Danmark) (da-DK)’ setting? Or even fall back to the danish_da.properties file if the other one was not present? Did I miss a setting? It falls back to the phrases.properties files, if the language setting is not set to ‘Dansk (da)’ but to ‘Dansk (Danmark) (da-DK)’. It works now with the language set to Dansk (da), but I am wondering if this is due to a bug or something I missed.