Skip to content

Instantly share code, notes, and snippets.

@odrobnik
Created November 19, 2015 16:45
Show Gist options
  • Save odrobnik/dc8335e936e04b0b1c89 to your computer and use it in GitHub Desktop.
Save odrobnik/dc8335e936e04b0b1c89 to your computer and use it in GitHub Desktop.
modified = @"Fri, 02 Oct 2015 16:20:34 CEST";
NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
[dateFormatter setDateFormat:@"EEE, dd MMM yyyy HH:mm:ss zzz"];
NSLocale *locale = [[NSLocale alloc] initWithLocaleIdentifier:@"en_US"];
[dateFormatter setLocale:locale];
_lastModifiedDate = [dateFormatter dateFromString:modified];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment