- MomentJS Tutorial
- MomentJS - Home
- MomentJS - Overview
- MomentJS - Environment Setup
- MomentJS - Introduction
- MomentJS - Parsing Date And Time
- MomentJS - Date Validation
- MomentJS - Getter/Setter
- Manipulate Date And Time
- Formatting Date And Time
- MomentJS - Date Queries
- MomentJS - Internationalization
- MomentJS - Customization
- MomentJS - Durations
- MomentJS - Utilities
- MomentJS - Plugins
- MomentJS - Examples
- MomentJS Useful Resources
- MomentJS - Quick Guide
- MomentJS - Useful Resources
- MomentJS - Discussion
MomentJS - parseZone
This method parses the string provided and keeps the resulting moment in a fixed timezone.
Syntax
moment.parseZone() moment.parseZone(String)
Example
var a = moment().parseZone();
Output
moment.parseZone is similar to using moment.utcOffset with a string.
Example
var a = moment("2013-01-01T00:00:00-13:00").utcOffset("2013-01-01T00:00:00-13:00"); var b = moment.parseZone("2013-01-01T00:00:00-13:00");
Output
momentjs_parsing_date_and_time.htm
Advertisements