Alex Rivera | Logout

Datepicker jQuery UI ... set language

Asked 2011-03-16T22:09:19.340
14

I tried to set Datepicker, like this:

<script type="text/javascript">
    $.datepicker.setDefaults($.datepicker.regional['nl']);
    $(function () {
        $("#tbDateDiagnostic").datepicker({
            numberOfMonths: 2,
            showButtonPanel: true,
            ateFormat: 'dd/mm/yy'
        });

        $("#tbDateSend").datepicker({
            numberOfMonths: 2,
            showButtonPanel: true,
            dateFormat : 'dd/mm/yy'
        });
    });
</script>

But all the time, the datepicker is in French and not in Dutch.

Did I do something wrong?

Edit
Report

1 Answer

23

I'm guessing you forgot to include the localisation file:

<script src="https://jquery-ui.googlecode.com/svn-history/r3982/trunk/ui/i18n/jquery.ui.datepicker-nl.js"></script>

You may find other localisation files here: https://github.com/jquery/jquery-ui/tree/master/ui/i18n

Here's a demo: http://jsfiddle.net/repw4/418/

answered 2011-04-03T01:41:07.800

Your Answer