Flo Flo - 2 months ago 11x
Javascript Question

jQuery datepicker not showing, initialization call is executed

My jQuery datepicker has stopped working...it no longer shows the datepicker on click of an input field. There are no console errors.

I already checked for a solution here.

So I tried adding a new CSS style:

<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css">

That did not help.

Another proposed solution was soo check for a duplicate occurrence of
clip: rect(0 0 0 0);
, but that is not the case either.

I also tried explicitly calling
on the input field after initialization, but that does not help either.

I also inspected the HTML, but I can't find the HTML for the datepicker so I can't even see what classes are assigned and if that is messing things up.

Here's my code:

(I added a breakpoint and the
call is executed.)

<input name="ctl00$CPHCenter$tbReservationDate" type="text" maxlength="14" id="tbReservationDate" class="textbox" placeholder="Datum Reservering" style="width:80%;">

$(function () {
$("#tbReservationDate").datepicker({ dateFormat: 'dd-mm-yy', firstDay: 1 });


You have two elements in your html with id="tbReservationDate".

The first one that appears in the DOM is the one in the popup (and there the datepicker works). Change the id or use a class to initialize the datepicker.