In what format is this date string?

前端 未结 2 1981
萌比男神i
萌比男神i 2020-12-11 06:35

Im trying to convert a bunch of NSStrings into NSDate objects. Here is an example string:

2013-04-25T15:51:30.427+1.00

But I can\'t figure

2条回答
  •  醉梦人生
    2020-12-11 06:57

    The proper format is yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ.

    See Unicode Date Format Patterns.

    Also, the ZZZZZ format for the +00:00 timezone format was added to iOS 6 and is not supported under iOS 5 or earlier.

提交回复
热议问题