The locales listed in the Select Locale screen are controlled by the
locales.available property in general.properties. If you are only seeing
two locales listed, then it is because you changed the locales.available
property to display only two locales.
The locale.properties.fallback property in general.properties should not
be changed. Changing it to de will throw exceptions when there is no de
translation found (which is often the case). When you change that
property to de, you are telling OFBiz, "If you can't find a German
translation, then fall back to the German translation" - which wouldn't
make any sense.
If your intention is to make German the default language, then you want
to change the ofbiz.locale.default property in start.properties.
-Adrian
madppiper wrote:
ah,
this is odd, on the demo server there isn't really anything wrong at all.
Perhaps I should describe the problem on my server then. The language ftl
file on my server produces the following code:
<div id="choose-language" class="screenlet">
<div class="screenlet-header">
<div class="boxhead">Sprache</div>
</div>
<div class="screenlet-body" style="text-align: center;">
<form method="post" name="chooseLanguage"
action="/ecommerce/control/setSessionLocale" style="margin: 0pt;">
<select name="newLocale" class="selectBox" style="width: 95%;"
onchange="submit()">
<option dir="ltr" value="en" lang="en">English</option>
<option dir="ltr" value="de" lang="de">Deutsch</option>
</select>
</form>
</div>
</div>
I left the language.ftl itself untouched:
<div id="choose-language" class="screenlet">
<div class="screenlet-header">
<div class="boxhead">${uiLabelMap.CommonLanguageTitle}</div>
</div>
<div class="screenlet-body" style="text-align: center;">
<form method="post" name="chooseLanguage"
action="<@ofbizUrl>setSessionLocale</@ofbizUrl>" style="margin: 0;">
<select name="newLocale" class="selectBox" style="width:95%"
onchange="submit()">
<#assign availableLocales =
Static["org.ofbiz.base.util.UtilMisc"].availableLocales()/>
<#list availableLocales as availableLocale>
<#assign langAttr = availableLocale.toString()?replace("_",
"-")>
<#assign langDir = "ltr">
<#if "ar.iw"?contains(langAttr?substring(0, 2))>
<#assign langDir = "rtl">
</#if>
<option lang="${langAttr}" dir="${langDir}"
value="${availableLocale.toString()}"<#if locale.toString() =
availableLocale.toString()>
selected="selected"</#if>>${availableLocale.getDisplayName(availableLocale)}</option>
</#list>
</select>
</form>
</div>
</div>
but I did edit the general.properties file and set the following:
locale.properties.fallback=de
# -- locales made available separated by commas
locales.available=de,en
Perhaps this is really a configuration mishap of mine (which would actually
solve several problems of mine at once ;) ), but why would it only display
the first two chars of the actual localeString?