here is a snippet of code I used in an application
[NSString stringWithContentsOfURL:] is deprecated for now. You have to use:
NSString *locationStr = [NSString stringWithContentsOfURL:[NSURL URLWithString:urlStr] encoding:NSUTF8StringEncoding error:nil];