As a small excercise for myself i decided to have a better look at how locales are defined in .net and dnn.
Of course, i found this page, and read that page many times before, however, i discovered some new (to me anyway) information (i sometimes overlook the most obvious information):
http://tinyurl.com/agvah (a page on msdn, i tinyurled it to make the url fit here...). The first thing that comes to mind is that DotNetNuke should also support language only locales (ie. nl instead of only nl-NL and nl-BE), to accomodate for generic languages.
An other observation, somewhat new to me, but that may be my crosseyed [EMO]glasses.gif[/EMO] reading sometimes, is the fact that locales can also have suffixes, like -Cyrl for Cyrillic script and -Latn for Latin script:
The culture names follow the RFC 1766 standard in the format "<languagecode2>-<country/regioncode2>", where <languagecode2> is a lowercase two-letter code derived from ISO 639-1 and <country/regioncode2> is an uppercase two-letter code derived from ISO 3166. For example, U.S. English is "en-US". In cases where a two-letter language code is not available, the three-letter code derived from ISO 639-2 is used; for example, the three-letter code "div" is used for cultures that use the Dhivehi language. Some culture names have suffixes that specify the script; for example, "-Cyrl" specifies the Cyrillic script, "-Latn" specifies the Latin script.
So the maximum length for a locale key is actually 10, and not 6 as currently used in DotNetNuke (for instance, the field DefaultLanguage in table Portals is only 6 characters wide). People trying to make language packs for those languages will be in trouble...
Next i saw a post (which i cant seem to find anymore) about someone not being able to see text in their language, which was indian or something. I tried to find out what would be causing this behaviour, and, when i looked at the language pulldown, some of the languages were not rendered correctly at my system either:
(the incorrectly rendered languages are Armenian and Georgian) This is at least some prove that not all languages render correctly in Internet Explorer. Some further investigation would be needed here.
As a last excercise i compared the .net locale names to the locale names in dotnetnuke:
.NET 1.1 |
|
DotNetNuke |
CultureName |
Language-Country/Region |
|
CultureName |
Language-Country/Region |
af-ZA |
Afrikaans - South Africa |
|
af-ZA |
Afrikaans (Suid Afrika) |
ar-AE |
Arabic - United Arab Emirates |
|
ar-AE |
العربية (الإمارات العربية المتحدة) |
ar-BH |
Arabic - Bahrain |
|
ar-BH |
العربية (البحرين) |
ar-DZ |
Arabic - Algeria |
|
ar-DZ |
العربية (الجزائر) |
ar-EG |
Arabic - Egypt |
|
ar-EG |
العربية (مصر) |
ar-IQ |
Arabic - Iraq |
|
ar-IQ |
العربية (العراق) |
ar-JO |
Arabic - Jordan |
|
ar-JO |
العربية (الأردن) |
ar-KW |
Arabic - Kuwait |
|
ar-KW |
العربية (الكويت) |
ar-LB |
Arabic - Lebanon |
|
ar-LB |
العربية (لبنان) |
ar-LY |
Arabic - Libya |
|
ar-LY |
العربية (ليبيا) |
ar-MA |
Arabic - Morocco |
|
ar-MA |
العربية (المملكة المغربية) |
ar-OM |
Arabic - Oman |
|
ar-OM |
العربية (عمان) |
ar-QA |
Arabic - Qatar |
|
ar-QA |
العربية (قطر) |
ar-SA |
Arabic - Saudi Arabia |
|
ar-SA |
العربية (المملكة العربية السعودية) |
ar-SY |
Arabic - Syria |
|
ar-SY |
العربية (سوريا) |
ar-TN |
Arabic - Tunisia |
|
ar-TN |
العربية (تونس) |
ar-YE |
Arabic - Yemen |
|
ar-YE |
العربية (اليمن) |
az-AZ-Cyrl |
Azeri (Cyrillic) - Azerbaijan |
|
az-AZ-Cyrl |
Азәрбајҹан (Азәрбајҹан) |
az-AZ-Latn |
Azeri (Latin) - Azerbaijan |
|
az-AZ-Latn |
Azərbaycan­ılı (Azərbaycanca) |
be-BY |
Belarusian - Belarus |
|
be-BY |
Беларускі (Беларусь) |
bg-BG |
Bulgarian - Bulgaria |
|
bg-BG |
български (България) |
ca-ES |
Catalan - Catalan |
|
ca-ES |
català (català) |
cs-CZ |
Czech - Czech Republic |
|
cs-CZ |
čeština (Česká republika) |
da-DK |
Danish - Denmark |
|
da-DK |
dansk (Danmark) |
de-AT |
German - Austria |
|
de-AT |
Deutsch (Österreich) |
de-CH |
German - Switzerland |
|
de-CH |
Deutsch (Schweiz) |
de-DE |
German - Germany |
|
de-DE |
Deutsch (Deutschland) |
de-LI |
German - Liechtenstein |
|
de-LI |
Deutsch (Liechtenstein) |
de-LU |
German - Luxembourg |
|
de-LU |
Deutsch (Luxemburg) |
div-MV |
Dhivehi - Maldives |
|
div-MV |
ދިވެހިބަސް (ދިވެހި ރާއްޖެ) |
el-GR |
Greek - Greece |
|
el-GR |
ελληνικά (Ελλάδα) |
en-AU |
English - Australia |
|
en-AU |
English (Australia) |
en-BZ |
English - Belize |
|
en-BZ |
English (Belize) |
en-CA |
English - Canada |
|
en-CA |
English (Canada) |
en-CB |
English - Caribbean |
|
en-CB |
English (Caribbean) |
en-GB |
English - United Kingdom |
|
en-GB |
English (United Kingdom) |
en-IE |
English - Ireland |
|
en-IE |
English (Eire) |
en-JM |
English - Jamaica |
|
en-JM |
English (Jamaica) |
en-NZ |
English - New Zealand |
|
en-NZ |
English (New Zealand) |
en-PH |
English - Philippines |
|
en-PH |
English (Philippines) |
en-TT |
English - Trinidad and Tobago |
|
en-TT |
English (Trinidad y Tobago) |
en-US |
English - United States |
|
en-US |
English (United States) |
en-ZA |
English - South Africa |
|
en-ZA |
English (South Africa) |
en-ZW |
English - Zimbabwe |
|
en-ZW |
English (Zimbabwe) |
es-AR |
Spanish - Argentina |
|
es-AR |
Español (Argentina) |
es-BO |
Spanish - Bolivia |
|
es-BO |
Español (Bolivia) |
es-CL |
Spanish - Chile |
|
es-CL |
Español (Chile) |
es-CO |
Spanish - Colombia |
|
es-CO |
Español (Colombia) |
es-CR |
Spanish - Costa Rica |
|
es-CR |
Español (Costa Rica) |
es-DO |
Spanish - Dominican Republic |
|
es-DO |
Español (República Dominicana) |
es-EC |
Spanish - Ecuador |
|
es-EC |
Español (Ecuador) |
es-ES |
Spanish - Spain |
|
es-ES |
español (España) |
es-GT |
Spanish - Guatemala |
|
es-GT |
Español (Guatemala) |
es-HN |
Spanish - Honduras |
|
es-HN |
Español (Honduras) |
es-MX |
Spanish - Mexico |
|
es-MX |
Español (México) |
es-NI |
Spanish - Nicaragua |
|
es-NI |
Español (Nicaragua) |
es-PA |
Spanish - Panama |
|
es-PA |
Español (Panamá) |
es-PE |
Spanish - Peru |
|
es-PE |
Español (Perú) |
es-PR |
Spanish - Puerto Rico |
|
es-PR |
Español (Puerto Rico) |
es-PY |
Spanish - Paraguay |
|
es-PY |
Español (Paraguay) |
es-SV |
Spanish - El Salvador |
|
es-SV |
Español (El Salvador) |
es-UY |
Spanish - Uruguay |
|
es-UY |
Español (Uruguay) |
es-VE |
Spanish - Venezuela |
|
es-VE |
Español (Republica Bolivariana de Venezuela) |
et-EE |
Estonian - Estonia |
|
et-EE |
eesti (Eesti) |
eu-ES |
Basque - Basque |
|
eu-ES |
euskara (euskara) |
fa-IR |
Farsi - Iran |
|
fa-IR |
فارسى (ايران) |
fi-FI |
Finnish - Finland |
|
fi-FI |
suomi (Suomi) |
fo-FO |
Faroese - Faroe Islands |
|
fo-FO |
føroyskt (Føroyar) |
fr-BE |
French - Belgium |
|
fr-BE |
français (Belgique) |
fr-CA |
French - Canada |
|
fr-CA |
français (Canada) |
fr-CH |
French - Switzerland |
|
fr-CH |
français (Suisse) |
fr-FR |
French - France |
|
fr-FR |
français (France) |
fr-LU |
French - Luxembourg |
|
fr-LU |
français (Luxembourg) |
fr-MC |
French - Monaco |
|
fr-MC |
français (Principauté de Monaco) |
gl-ES |
Galician - Galician |
|
gl-ES |
galego (galego) |
gu-IN |
Gujarati - India |
|
gu-IN |
ગુજરાતી (ભારત) |
he-IL |
Hebrew - Israel |
|
he-IL |
עברית (ישראל) |
hi-IN |
Hindi - India |
|
hi-IN |
हिंदी (भारत) |
hr-HR |
Croatian - Croatia |
|
hr-HR |
hrvatski (Hrvatska) |
hu-HU |
Hungarian - Hungary |
|
hu-HU |
Magyar (Magyarország) |
hy-AM |
Armenian - Armenia |
|
hy-AM |
Հայերեն (Հայաստան) |
id-ID |
Indonesian - Indonesia |
|
id-ID |
Bahasa Indonesia (Indonesia) |
is-IS |
Icelandic - Iceland |
|
is-IS |
íslenska (Ísland) |
it-CH |
Italian - Switzerland |
|
it-CH |
italiano (Svizzera) |
it-IT |
Italian - Italy |
|
it-IT |
italiano (Italia) |
ja-JP |
Japanese - Japan |
|
ja-JP |
日本語 (日本) |
ka-GE |
Georgian - Georgia |
|
ka-GE |
ქართული (საქართველო) |
kk-KZ |
Kazakh - Kazakhstan |
|
kk-KZ |
Қазақ (Қазақстан) |
kn-IN |
Kannada - India |
|
kn-IN |
ಕನ್ನಡ (ಭಾರತ) |
kok-IN |
Konkani - India |
|
kok-IN |
कोंकणी (भारत) |
ko-KR |
Korean - Korea |
|
ko-KR |
한국어 (대한민국) |
ky-KZ |
Kyrgyz - Kazakhstan |
|
ky-KZ |
Кыргыз (Кыргызстан) |
lt-LT |
Lithuanian - Lithuania |
|
lt-LT |
lietuvių (Lietuva) |
lv-LV |
Latvian - Latvia |
|
lv-LV |
latviešu (Latvija) |
mk-MK |
Macedonian - FYROM |
|
mk-MK |
македонски јазик (Македонија) |
mn-MN |
Mongolian - Mongolia |
|
mn-MN |
Монголáхэл (Монголáулс) |
mr-IN |
Marathi - India |
|
mr-IN |
मराठी (भारत) |
ms-BN |
Malay - Brunei |
|
ms-BN |
Bahasa Malaysia (Brunei Darussalam) |
ms-MY |
Malay - Malaysia |
|
ms-MY |
Bahasa Malaysia (Malaysia) |
nb-NO |
Norwegian (Bokmål) - Norway |
|
nb-NO |
norsk (bokmål) (Norge) |
nl-BE |
Dutch - Belgium |
|
nl-BE |
Nederlands (België) |
nl-NL |
Dutch - The Netherlands |
|
nl-NL |
Nederlands (Nederland) |
nn-NO |
Norwegian (Nynorsk) - Norway |
|
nn-NO |
norsk (nynorsk) (Noreg) |
pa-IN |
Punjabi - India |
|
pa-IN |
ਪੰਜਾਬੀ (ਭਾਰਤ) |
pl-PL |
Polish - Poland |
|
pl-PL |
polski (Polska) |
pt-BR |
Portuguese - Brazil |
|
pt-BR |
Português (Brasil) |
pt-PT |
Portuguese - Portugal |
|
pt-PT |
português (Portugal) |
ro-RO |
Romanian - Romania |
|
ro-RO |
română (România) |
ru-RU |
Russian - Russia |
|
ru-RU |
русский (Россия) |
sa-IN |
Sanskrit - India |
|
sa-IN |
संस्कृत (भारतम्) |
sk-SK |
Slovak - Slovakia |
|
sk-SK |
slovenčina (Slovenská republika) |
sl-SI |
Slovenian - Slovenia |
|
sl-SI |
slovenski (Slovenija) |
sq-AL |
Albanian - Albania |
|
sq-AL |
shqipe (Shqipëria) |
sr-SP-Cyrl |
Serbian (Cyrillic) - Serbia |
|
sr-SP-Cyrl |
српски (СрбијаáиáЦрнаáГора) |
sr-SP-Latn |
Serbian (Latin) - Serbia |
|
sr-SP-Latn |
srpski (Srbija i Crna Gora) |
sv-FI |
Swedish - Finland |
|
sv-FI |
svenska (Finland) |
sv-SE |
Swedish - Sweden |
|
sv-SE |
svenska (Sverige) |
sw-KE |
Swahili - Kenya |
|
sw-KE |
Kiswahili (Kenya) |
syr-SY |
Syriac - Syria |
|
syr-SY |
ܣܘܪܝܝܐ (سوريا) |
ta-IN |
Tamil - India |
|
ta-IN |
தமிழ் (இந்தியா) |
te-IN |
Telugu - India |
|
te-IN |
తెలుగు (భారతáదేశం) |
th-TH |
Thai - Thailand |
|
th-TH |
ไทย (ไทย) |
tr-TR |
Turkish - Turkey |
|
tr-TR |
Türkçe (Türkiye) |
tt-RU |
Tatar - Russia |
|
tt-RU |
Татар (Россия) |
uk-UA |
Ukrainian - Ukraine |
|
uk-UA |
україньска (Україна) |
ur-PK |
Urdu - Pakistan |
|
ur-PK |
اُردو (پاکستان) |
uz-UZ-Cyrl |
Uzbek (Cyrillic) - Uzbekistan |
|
uz-UZ-Cyrl |
Ўзбек (Ўзбекистон) |
uz-UZ-Latn |
Uzbek (Latin) - Uzbekistan |
|
uz-UZ-Latn |
U'zbek (U'zbekiston Respublikasi) |
vi-VN |
Vietnamese - Vietnam
|
|
vi-VN |
Tiếng Việt Nam (Việt Nam) |
zh-CHS |
Chinese (Simplified) |
|
|
|
zh-CHT |
Chinese (Traditional) |
|
|
|
zh-CN |
Chinese - China |
|
zh-CN |
中文(简体) (中华人民共和国) |
zh-HK |
Chinese - Hong Kong SAR |
|
zh-HK |
中文(繁體) (香港特别行政区) |
zh-MO |
Chinese - Macau SAR |
|
zh-MO |
中文(简体) (澳门特别行政区) |
zh-SG |
Chinese - Singapore |
|
zh-SG |
中文(简体) (新加坡) |
zh-TW |
Chinese - Taiwan |
|
zh-TW |
中文(繁體) (台灣) |
Either the .net documentation is wrong, or something else is going on. According to the documentation all languages start with capitals, however, in reality this is not the case. Maybe its possible to compensate for this in DotNetNuke...
Cheers,
Erik