title: How to save date time format in CakePHP (pass the date from JS to CakePHP)
body: <p>I have a datetime variable in JS which is:</p>
  
  <pre><code>var date_start   = dateFormat(newJobForm.time_start, "yyyy-mm-dd-HH-MM"); 
  var date_end     = dateFormat(newJobForm.time_end, "yyyy-mm-dd-HH-MM"); 
  </code></pre>
  
  <p>The main problem is: I can't show the minutes only</p>
  
  <p>When I pass my dates to PHP's <code>date()</code> function, because of the <code>:</code> between <code>H</code> and <code>i</code>, it won't save it. I tried to <code>explode()</code> it with <code>-</code> but it didn't work.</p>
  
  <p>The URL is: <code>my_controller/abcd^5^2012-10-15-15-15^2012-10-18-17-30</code> and my controller in CakePHP action to take the time from JS is:</p>
  
  <pre><code>$time_start          = $explode_item[2];                 
  $time_end            = $explode_item[3]; 
  
  $dateStart = strtotime ( date('Y-m-d H:i', $time_start) ) ;
              $dateStartArray['Y'] = date ( 'Y' , $dateStart );
              $dateStartArray['m'] = date ( 'm' , $dateStart );
              $dateStartArray['d'] = date ( 'd' , $dateStart );
              $dateStartArray['H'] = date ( 'H' , $dateStart );
              $dateStartArray['i'] = date ( 'i' , $dateStart );
  </code></pre>