I’m localising out current site and therefore aplying the JSF convertDatetime tag to all dates.
I have set the dateStyle to ‘short’
For Internet Explorer with locale of pt_PT dates will show as ’13-01-2012′.
While for Chrome with locale of pt_PT they show as ’13-01-2012′.
Both these are fine.
A problem occurs with firefox; it does’nt seem to have a ‘pt_PT’ option!
So I select the ‘pt’ option instead.
A problem occurs in that the facescontect cannot find this locale:
setLocale(getFacesContext().getViewRoot().getLocale());
I know this as the above code return a locale of ‘en_US’, the next locale in the browser list.
Is this a known issue with firefox?
My faces-config is as follows:
<application>
<locale-config>
<default-locale>en_GB</default-locale>
<supported-locale>en_IE</supported-locale>
<supported-locale>en_US</supported-locale>
<supported-locale>en_AU</supported-locale>
<supported-locale>en_NZ</supported-locale>
<supported-locale>en_GB</supported-locale>
<supported-locale>fr_BE</supported-locale>
<supported-locale>fr_CA</supported-locale>
<supported-locale>fr_FR</supported-locale>
<supported-locale>fr_LU</supported-locale>
<supported-locale>fr_MC</supported-locale>
<supported-locale>fr_CH</supported-locale>
<supported-locale>pt_PT</supported-locale>
<supported-locale>pt_BR</supported-locale>
</locale-config>
<view-handler>org.ajax4jsf.application.AjaxViewHandler</view-handler>
<message-bundle>com.resource.conversionmessages</message-bundle>
<variable-resolver>org.springframework.web.jsf.DelegatingVariableResolver</variable-resolver>
<el-resolver>org.springframework.web.jsf.el.SpringBeanFacesELResolver</el-resolver>
</application>
Thanks
Thanks
I simply added the following line to my supported locales in faces-config: