Forum



18:51

10/08/2009

Hello Tony,
It seems to me that some settings from German and English locals (grid.locale-de.js and grid.locale-en.js) were wrong. I know that Windows has very nice API (like GetLocaleInfoEx) which allows to get different locale specific information like LOCALE_STHOUSAND, LOCALE_S1159 (AM designator), LOCALE_S2359 (PM designator) and so on. So I wrote a small program to verify information from some selected grid.locale-XX.js files which seems me especially suspected.
I could find out, that for example the thousandsSeparator in English must be "," instead of " ". The blank character " " is correct for Russian and Bulgaria locale, so for you and for me it looks OK, nevertheless it is wrong as the thousands separator in English. On the same way I could verified my other suggestions, that AmPm array in German and Russian locale must be ["","","",""] as in Bulgarian locale and not ["am","pm","AM","PM"] as currently. In the same way I could verify that AmPm : ["am","pm","AM","PM"] in grid.locale-ja.js is wrong. It sould be ["åˆå‰","åˆå¾Œ","åˆå‰","åˆå¾Œ"]. Exaclty in the same way I verified that just published Persian locale contain also many wrong information. The grid.locale-fa.js has AmPm: ["ب., "ب.ظ", "Ù‚.ظ", "Ù‚.ظ"] which is definitively wrong because two first characters ("am","pm") are the same and next two (which must be "AM","PM") has another value and are also the same. Correct value must be AmPm: ["ب.ظ", "ب.ظ", "Ù‚.ظ", "Ù‚.ظ"]. The value of monthNames (monthNames: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "ژانويه", "Ùوريه", "مارس", "آوريل", "مه", "ژوئن", "ژوئيه", "اوت", "سپتامبر", "اکتبر", "نوامبر", "December"]) is also definitively wrong at least because of the number of months. I can continue.
First of all I wanted to post the long bug report and suggestion to move some settings like ISO8601Long, ISO8601Short, baseLinkUrl, showAction and so on from the grid.locale-XX.js files in the grid.base.js. I think that such movement of the information which must be the same in all locales has sense. About the information like AmPm, monthNames and thousandsSeparator I have now quite another approach.
Occasionally I find out that Microsoft made jQuery Globalization plugin, which support more as 350 locales and Calendar which are not only Gregorian, but Japanese for example and which in my opinion would be the best way of Globalization of dates, numbers and currency.
I recommend you to look at the following live demos:
http://infinity88.com/jquery-glob/demo/demo.html
http://infinity88.com/jquery-glob/demo/demo-datepicker.html
jQuery Globalization plugin is distributed under the same license as core jQuery.js. (see http://jquery-howto.blogspot.com/2010/10/jquery-globalization-plugin.html).
How one can read in the statement of John Resig (http://blog.jquery.com/2010/10/04/new-official-jquery-plugins-provide-templating-data-linking-and-globalization/): The jQuery Globalization plugin together with some other plugins „have been accepted as officially supported plugins of the jQuery project“.
Intoduction of jQuery Globalization Plugin (published on GitHub: https://github.com/nje/jquery-glob/
http://weblogs.asp.net/scottgu/archive/2010/06/10/jquery-globalization-plugin-from-microsoft.aspx
Mostly the information published as the jQuery Globalization plugin could be better made as general JavaScript library, but for our purpose jQuery plugin is also very good.
I recommend you Tony to look at jQuery Globalization plugin. It seems to me that the usage of this plugin could reduce the code of grid.locale-XX.js so, that there contain the texts which should be really translated.
Your opinion Tony about this suggestion is interesting for me.
Best regards
Oleg
14:25

Moderators
30/10/2007

Oleg,
I will definitley look into this.
Please refer here:
http://www.trirand.com/blog/?p.....-is-false/
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Most Users Ever Online: 715
Currently Online:
172 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66