hi every one I'm using this code, through this I'm getting wrong time,i need time with GMT format but it showing without GMT, that is by using this I'm getting time 2011-11-01 07:30:11 +0000 while the current time here right now is 12:30 pm. please help me in getting Current date and time in GMT format. thanks.
NSDate *today = [NSDate date];
NSString *str= [NSString stringWithFormat:@"todaysss daterrrr----%@",today];
NSLog(@"todayssss date time-------- %@",str);
NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
// display in 12HR/24HR (i.e. 11:25PM or 23:25) format according to User Settings
[dateFormatter setTimeStyle:NSDateFormatterShortStyle];
NSString *currentTime = [dateFormatter stringFromDate:today];
[dateFormatter release];