title: jQuery UI datepicker doesn't close on the iPad
body: <p>The datepicker usually works on the PC, but not in iPad's browser. In <code>beforeShow</code>, I add the button to close:</p>
  
  <pre><code>var headerPane = $("#ui-datepicker-div");
  headerPane.append("&lt;a href='javascript:void(0);' class='close-datepicker'&gt;");
  </code></pre>
  
  <p>Close:</p>
  
  <pre><code>closeDatePicker: function(){
      $.datepicker._hideDatepicker();
  } ...
  </code></pre>
  
  <p>In events have the click:</p>
  
  <pre><code>Events: function(){
    $('body').on('click', '.close-datepicker' this.closeDatePicker)
  }
  </code></pre>
  
  <p>I've tried with <code>.datepicker("hide")</code> and also nothing.</p>