title: Date Time Jquery datetimepicker
body: <p>I am having trouble with displaying a date time on a page in a Textbox. See on Fiddle: <a href="http://jsfiddle.net/LkpPJ/5/" rel="nofollow">http://jsfiddle.net/LkpPJ/5/</a></p>
  
  <p>Internet explorer and Firefox show: 2013-12-16T01:00</p>
  
  <p>Chrome shows: 12/16/2013 01:00 AM</p>
  
  <p>Javascript Console in Internet explorer and Firefox says:</p>
  
  <blockquote>
    <p>Error parsing the date/time string: Unexpected literal at position 2
    date/time string = 2013-12-16T01:00 timeFormat = hh:mm TT dateFormat =
    mm/dd/yy</p>
  </blockquote>
  
  <p><strong>ASP.NET C# Code:</strong></p>
  
  <pre><code>StartDatePicker.Text = dtStartDate.ToString("yyyy-MM-ddTHH:mm");
  &lt;asp:TextBox ID="EndDatePicker" runat="server" CssClass="rounded dateinput" ClientIDMode="Static" TextMode="DateTimeLocal"&gt;&lt;/asp:TextBox&gt;
  &lt;asp:TextBox ID="StartDatePicker" runat="server" CssClass="rounded dateinput" ClientIDMode="Static" TextMode="DateTimeLocal"&gt;&lt;/asp:TextBox&gt;
  </code></pre>
  
  <p>Javascript code:</p>
  
  <pre><code> if (!Modernizr.inputtypes.date) {
          $(function () {
              $("#StartDatePicker").datetimepicker({
                  timeFormat: "hh:mm TT",
  
                  minuteGrid: 10,
                  addSliderAccess: true,
                  sliderAccessArgs: { touchonly: false }
              });
          });
      };
      if (!Modernizr.inputtypes.date) {
          $(function () {
              $("#EndDatePicker").datetimepicker({
                  timeFormat: "hh:mm TT",
  
                  minuteGrid: 10,
                  addSliderAccess: true,
                  sliderAccessArgs: { touchonly: false }
              });
          });
      };
  </code></pre>