You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are a number of languages in the i18n plugin where there are country-specific versions of the language files but no basic versions. For example there are sv-SE.* files but no sv.* files.
This causes problems for applications that choose a language file, eg using PHP's Locale::lookup() method, based on a user-specified locale, either via a config setting or via the browser language preferences. For example, if the locale is set to 'sv' then the 'sv-SE' file will not be found. The RFC 4647 lookup algorithm used by Locale:lookup() allows for falling back from, eg, 'sv-SE' to 'sv' but not the other way round.
There should be a basic language file for all languages where there is a country-specific version. In most cases this will be a simple matter of copying the main country-specific version, eg 'sv-SE' to 'sv, 'de-DE' to 'de', 'nl-NL' to 'nl', etc.
The text was updated successfully, but these errors were encountered:
campbell-m
changed the title
i18n plugin missiung basic language versions for languages where country-specific versions exist
i18n plugin missing basic language versions for languages where country-specific versions exist
Sep 10, 2023
Thank you for filing this. Yes, it would make sense to follow RFC-4647 for our language file names. I'll look to look into that, although I can't say when I'll get time to do so yet.
campbell-m
added a commit
to meeting-room-booking-system/mrbs-code
that referenced
this issue
Sep 17, 2023
There are a number of languages in the i18n plugin where there are country-specific versions of the language files but no basic versions. For example there are sv-SE.* files but no sv.* files.
This causes problems for applications that choose a language file, eg using PHP's Locale::lookup() method, based on a user-specified locale, either via a config setting or via the browser language preferences. For example, if the locale is set to 'sv' then the 'sv-SE' file will not be found. The RFC 4647 lookup algorithm used by Locale:lookup() allows for falling back from, eg, 'sv-SE' to 'sv' but not the other way round.
There should be a basic language file for all languages where there is a country-specific version. In most cases this will be a simple matter of copying the main country-specific version, eg 'sv-SE' to 'sv, 'de-DE' to 'de', 'nl-NL' to 'nl', etc.
The text was updated successfully, but these errors were encountered: