Forums

Datepicker Mootools Localization

perarg 13 Mar, 2012
Hello, i am using a form in multilanguage environment. There is a Datepicker Mootools text box in there. I am trying to figure out a way to make Datepicker multilanguage too. It is only in English right now.

Any suggestion or proposal is as always accepted with pleasure😉
GreyHead 13 Mar, 2012
Hi Perarg,

Is this ChronoForms v4?

If you have CFv4 RC3.2 or later the MooTools datapicker is included which comes with language files. For earlier releases using the MonkeyPhycics datepicker there are instructions in the DatePicker sticky thread in the CFv4 forum.

Bob
perarg 13 Mar, 2012
Hi Bob,

yes it is the latest version. I saw the language files, but there is no automatic switch between them...
(i am talking for example about days_abbr variable where you can change the name of months or days)
Max_admin 15 Mar, 2012
Hi,

I'm not sure if this is going to work but let's try it:

THIS IS for the MOOTOOLS DATEPICKER ONLY, its not available for J1.5 and not available in Chronoforms versions before V4 RC3.21

1- add a new "Load JS" action AFTER the "show html".
2- insert this code inside it:
Locale.use('fr-FR');

3- if the Date picker is now using french then replace "fr-FR" by "en-US"
4- in your multi language action, add the new key: en-US=fr-FR
or whatever language you need, here is a list of supported ones:

cs-CZ
de-DE
en-US
es-ES
fr-FR
he-IL
it-IT
nl-NL
pl-PL
pt-BR
ru-RU



Regards,
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
perarg 15 Mar, 2012
Very very very clever!

Respect Max... No words! Respect...
Max_admin 15 Mar, 2012
No problems, did it work ?🙂
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
perarg 15 Mar, 2012
It works like a charm... It is a solution indeed
This topic is locked and no more replies can be posted.