0
I would like to convert this date format:
Wed Jul 20 2016 17:55:00 GMT-0300 (BRT)
for this format:
2016-07-20T14:55:00.000-03:00
0
I would like to convert this date format:
Wed Jul 20 2016 17:55:00 GMT-0300 (BRT)
for this format:
2016-07-20T14:55:00.000-03:00
Browser other questions tagged javascript node.js
You are not signed in. Login or sign up in order to post.
The first format you have is String or is a Date Object?
– Sergio
It’s a string @Sergio
– Jonathan
That seems
new Date('Wed Jul 20 2016 17:55:00 GMT-0300 (BRT)').toISOString();
but with-03:00
at the end :/ Where you need to use this string?– Sergio
I’ll give you an example of my problem: I have a string
A data de hoje é date
. And I perform a replace, and where is the worddate
I substitute for2016-07-20T14:55:00.000-03:00
. So far so good, however, when I perform aconsole.log
, he shows:A data de hoje é Wed Jul 20 2016 17:55:00 GMT-0300 (BRT)
. I didn’t really understand why it converted itself to this format, but wanted to convert back.– Jonathan
@Sergio, you got it ?
– Jonathan