title: Uncaught SyntaxError: Unexpected number for type date
body: <p>I am retrieving the date and time from the database table and converting to string using the server side (ruby on rails)
  When I pass the date and time in the script variable I get the <code>Uncaught SyntaxError: Unexpected number</code> error.
     This is my code,for the last line I get the error</p>
  
  <pre><code> &lt;% @adminstart.each do |name| %&gt;
  &lt;% time = name.strtime %&gt;
  &lt;% date = name.date %&gt;
  &lt;% end %&gt;
  &lt;% t1_s = time.strftime("%H:%M")%&gt;
  &lt;% datetime = date.to_s+" "+t1_s %&gt; 
  var date = new Date(&lt;%= datetime %&gt;);
  </code></pre>
  
  <p>In the console I can see this</p>
  
  <pre><code>var date = new Date(2014-04-11 11:30);
  </code></pre>
  
  <p>The date and time is correct,but i dont know why it isnt getting parsed as a date</p>