title: jquery datepicker with current time
body: <p>I want to have time along with date in a text box on click of a button (12 hrs format).</p>
  
  <p>There is the code I have done so far. I am able to get the date but I want to record current time along with the current date.</p>
  
  <pre><code>$(function() {
      $("#datepicker1").datepicker({
          dateFormat: "yy-mm-dd hh:mm:ss"
      }).datepicker("setDate", "0");
  });
  
  &lt;input id="datepicker1"&gt;
  </code></pre>
  
  <p>hh:mm:ss is what I  thought of but its not working. Please guide.</p>
  
  <p>It can be either via JS or jquery its ok, but on click of button.</p>