PDA

View Full Version : Localization on Ext.picker.Date



davidverm
3 May 2012, 3:01 AM
Hi,

We are retrieving the culture information from the server and then sending it through to the client side, and then applying translations and date formats to some of the ExtJS controls. One thing I have noticed is that the longday format for Swedish language is 'den 'd MMMM yyyy so when the tool tips are displaying the d and then n is being resolved in the Ext.picker.Date so then the date will look somthing like '3e5 '3 May 2012.

To avoid this I have added a hard coded solution to escape these characters in the word 'den'. So now I am supplying the Ext.picker.Date longdayformat with \\de\\n .... and that works.

However, I was wondering if there is a better way of doing this that you are aware off? I am sure we can live with this solution, but would be nice if there is a more generic way of handling this. This is more of a way the php dates are resolved than an EXT issue, so I am just taking a shot in the dark. :)

Thanks in advance.

mitchellsimoens
7 May 2012, 6:49 AM
If it's going to be within the date format then you need to escape the letters.