Pass it to the Date constructor.
> var date = new Date('2012-04-15T18:06:08-07:00')
> date
Mon Apr 16 2012 04:06:08 GMT+0300 (EEST)
For more information about Date, check https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Date.
More Related Contents:
- How to add number of days to today’s date? [duplicate]
- jQuery UI DatePicker to show month year only
- how to parse a “dd/mm/yyyy” or “dd-mm-yyyy” or “dd-mmm-yyyy” formatted date string using JavaScript or jQuery [duplicate]
- Get first and last date of current month with JavaScript or jQuery [duplicate]
- How do I pre-populate a jQuery Datepicker textbox with today’s date?
- How to add/subtract dates with JavaScript?
- Function to convert timestamp to human date in javascript [duplicate]
- Get week of the month
- Convert normal date to unix timestamp
- How to get the hours difference between two date objects? [duplicate]
- Set date in input type date
- Javascript: parse a string to Date as LOCAL time zone
- How to split a string at the first `/` (slash) and surround part of it in a “?
- Get current date in DD-Mon-YYY format in JavaScript/Jquery
- JavaScript Detecting Valid Dates
- Find all the days in a month with Date object?
- Check if date is in the past Javascript
- Get age from Birthdate [duplicate]
- javascript date + 7 days
- How to check if a string is a legal “dd/mm/yyyy” date?
- moment.js isValid function not working properly
- Dynamically adding div on button click and changing Id of each?
- How to make page loaders/animations/transitions
- Get specific text from html tag jquery [duplicate]
- How to open a Bootstrap modal window using jQuery?
- How do I add an “Add to Favorites” button or link on my website?
- Run change event for select even when same option is reselected
- prevent touchstart when swiping
- Twitter bootstrap – Focus on textarea inside a modal on click
- How to select line of text in textarea