title: Twitter bootstrap datetime picker not co-operating with MySQL
body: <p>I have a view, like this:</p>
  
  <pre><code>&lt;div class="input-append date the_date"&gt;
      &lt;input data-format="yyyy-MM-dd HH:mm:ss" type="text" readonly&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>and js, like this:</p>
  
  <pre><code>var the_date = $('.the_date &gt; input').val();
  // [DATA FOR SERVER]:
  var data={ the_date : the_date }
  </code></pre>
  
  <p>And when I submit the date form, the data array is sent to a controller which inserts the date via a model function.</p>
  
  <p>However the selected date is NOT inserted to the database.</p>
  
  <p>I can alert(the_date); from js, I can echo $the_date; from the controller and I can even echo $the_date; from the model, however $the_date does not go into the database.</p>
  
  <p>I have a standard datetime field in MySQL called the_date which has the standard MySQL datetime format of "yyyy-MM-dd hh:mm:ss", and I can't figure out why the_date is not going into the db.</p>
  
  <p>I am using CodeIgniter's Active Record for inserts, and every other insert works fine.
  I can insert dates with:</p>
  
  <pre><code>'the_date' =&gt; date("Y-m-d H:i:s")
  </code></pre>
  
  <p>for example, and I can also say: </p>
  
  <pre><code>'the_date' =&gt; '2002-11-11 12:12:12')
  </code></pre>
  
  <p>But the default datetime of "0000-00-00 00:00:00" is inserted everytime I use the datetimepicker from Bootstrap....</p>