[ https://issues.apache.org/jira/browse/FLEX-22068?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Justin Mclean updated FLEX-22068: --------------------------------- Labels: easyfix easytest (was: ) > DateFormatter.parse does not correctly handle positive GMT offset (such as UK) > ------------------------------------------------------------------------------ > > Key: FLEX-22068 > URL: https://issues.apache.org/jira/browse/FLEX-22068 > Project: Apache Flex > Issue Type: Bug > Components: mx: General > Affects Versions: Adobe Flex SDK 3.4 (Release) > Environment: Affected OS(s): All OS Platforms > Affected OS(s): All OS Platforms > Language Found: English > Reporter: Adobe JIRA > Labels: easyfix, easytest > > Steps to reproduce: > 1. Create a date string with a positive offset (ex GMT+0100 such as the > offset in the UK) > 2. call DateFormatter.parse with the date value > 3. Observe the output > > Actual Results: > > The Date object fullYear return will be 100 (or whatever the positive offset > is) > > Expected Results: > > The date object should have the correct year as was in the date string > > Workaround (if any): > > extend DateFormatter and override parse, add the following before calling > super.parse: > var timezoneRegEx:RegExp = /(GMT|UTC)(-|\+)\d\d\d\d/ig; // account for both > negative and positive offset > str = str.replace(timezoneRegEx, ""); -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira