Finding a date in the genitive case in jQueryUI Datepicker

You need to make Russified enter the date using jQueryUI Datepicker. This plugin supports localization, however, months are displayed in the nominative case.


The figure shows that for the month header (2) is correct, but the input field (1) correctly should be "September 21".

Is there any way to do this? Plugin settings do not allow this normally, so you have to invent something new.
October 3rd 19 at 03:56
2 answers
October 3rd 19 at 03:58
Well, the standard approach, there are two variables for the month
monthNamesShort and monthNames.
Long description do not touch and short described by its input and output in the short.

$.datepicker.setDefaults( $.datepicker.regional[ "ru" ] );

 clickInput: true,
 monthNamesShort: [ "Jan", "Feb", "Mar", "APR", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ],
 dateFormat:"DD, d M yy",

<div class="input-prepend"> 
<span class="add-on"><i class="icon-calendar"></i></span>
 <input class="span5" id="myDate" type="text">
Thank you! This trick can really help - Adalberto.Jaskols commented on October 3rd 19 at 04:01
October 3rd 19 at 04:00
To modify yourself onSelect?
apparently Yes. I was hoping to see a ready-made solution is still the task for popular Russian-speaking Internet. It is strange that the search engines don't find anything like it. - Adalberto.Jaskols commented on October 3rd 19 at 04:03

Find more questions by tags JavaScriptjQueryWork with date / time