NSDate *nowDate = [NSDate new];
NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
[formatter setDateFormat:@"yyyy/MM/dd HH:mm:ss"];
//获取所有的时区名字
NSArray *array = [NSTimeZone knownTimeZoneNames];
// NSLog(@"array:%@",array);
//快速枚举法
for(NSString *timeZoneName in array){
[formatter setTimeZone:[NSTimeZone timeZoneWithName:timeZoneName]];
NSLog(@"%@,%@",timeZoneName,[formatter stringFromDate:nowDate]);
}
[formatter release];
[nowDate release];