The best solution I have found so far:

        // detect language
        $locale = new Zend_Locale;
        $lang = $locale->getLanguage();

        // change datepicker default language
        if ('en' !== $lang) {
            $this->view->JQuery()
               
->addJavascriptFile('http://jquery-ui.googlecode.com/svn/tags/latest/ui/minified/i18n/jquery-ui-i18n.min.js')
               
->addOnLoad('$.datepicker.setDefaults($.extend({showMonthAfterYear: false},
$.datepicker.regional[\''. $lang .'\']));');
        }

-- 
regards
takeshin


Jan Wagner wrote:
> 
>> How to enable translation of ZendX_JQuery DatePicker?
>> How to set 'regional' option?
>> I tried setJQueryParams and setOptions,
>> but nothing changes.
> 
> I do the following in my view script:
> 
> $this->jQuery()->addJavaScriptFile(
>      $this->baseUrl('/scripts/jquery/ui.datepicker-de.js')
> );
> 
> The file ui.datepicker-de.js should be part of jquery.
> 
> Cheers Jan
> 
> 

-- 
View this message in context: 
http://www.nabble.com/ZendX_JQuery-regional-tp24953515p24954986.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to