What’s the difference between datetime in ISO 8601 and UTC formats in javascript?

They’re for different purposes.

  • UTC is the primary time standard by which the world regulates clocks and time.
  • ISO is standard format time. ISO also supports ms in its format.

So if you want to send data to the server, send the ISO, because ISO is the standard format:

var date = new Date();
sendDate(date.toISOString());

You can also use toISOString in IE7 polyfill.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)