javascript - Converting date to milliseconds to date -


I ran into a strange problem. I'm sending a date in milliseconds using Javascript for my controller there, I Convert millisecond to PHP in a time stamp. It seems that part of its date is correct, but time is completely closed. Can anyone tell me what am I missing? The code is below.

Javascript

  var d = new date ("13 October 2014 11:13:00"); Document.write (d.getTime (+ + "Millesconds from 19/01/01/01);  

Results

  1413191580000  <   

 

Results

  2014-10-13 02:13:00  

I am feeling that this is happening because you have a date with a different timezone returned from the server from the server, according to ECMAScript standard () of a Javascript's UTC timestamp. G Standardize the time zones between the client and the server, and then you can be one on both dates. I always deal with the dates in the UTC on the server and then localize the client side timezone.


Comments

Popular posts from this blog

Editing Python Class in Shell and SQLAlchemy -

uislider - In a MATLAB GUI, how does one implement a continuously varying slider from a GUIDE created .m file? -

import - Python ImportError: No module named wmi -