JQuery UI datepicker not showing week numbers

My jquery UI datepicker does not show week numbers even if showWeek: true is set. Here is my code:

<script type='text/javascript'>
  $(document).ready(function(){
    $('#startDate').datepicker({ 
      changeMonth: true, 
      changeYear:true, 
      dateFormat: 'd-M-yy', 
      firstDay: 1, 
      showButtonPanel: true, 
      showWeek: true 
  });
});
</script>
<input type='text' name='startDate' id='startDate'>

From what I understand, you only need to set the showWeek parameter to do this job: weekHeading has a default value of "Wk", and calculateWeekNumber has a built-in ISO day calculator function.

Also, for some reason, the Today button on the button bar is disabled ?! Any advice would be most appreciated. Thank.

+3
source share
1 answer

, jQueryUI v1.7.2. v1.8, showWeek. v1.8rc3, .

: http://jsbin.com/eliki

+2

Source: https://habr.com/ru/post/1736293/


All Articles