我正在尝试使用以下方法从Google返回JSON:
NSString *urlString = [NSString stringWithFormat:@"http://maps.google.com.br/maps/api/directions/json?origin=%@&destination=%@&sensor=false", pointOrigem, pointDestino];
NSURL *url = [NSURL URLWithString:urlString];
NSURLRequest *request = [NSURLRequest requestWithURL:url];
[NSURLConnection connectionWithRequest:request delegate:self];
NSLog(@"%@", urlString);
正如您所看到的,我已经记录了网址,以确保一切正常。这是:
有人知道我的代码有什么问题吗? 谢谢你的帮助!