weather

Google Weather API gone?

雨燕双飞 提交于 2019-11-26 05:49:32
问题 I had been using the following google weather api in my iPhone apps to get 4 day weather forecast. NSString *address = @\"http://www.google.com/ig/api?weather=Chicago\"; NSString *request = [NSString stringWithFormat:@\"%@\",address]; NSLog(@\"request: %@\", request); NSURL *URL = [NSURL URLWithString:request]; NSError *error; NSString *XML = [NSString stringWithContentsOfURL:URL encoding:NSASCIIStringEncoding error:&error]; NSLog(@\"XML: %@\", XML); NSLog(@\"XML lenght: %d\", [XML length]);

Google Weather API gone?

我的梦境 提交于 2019-11-26 05:30:44
I had been using the following google weather api in my iPhone apps to get 4 day weather forecast. NSString *address = @"http://www.google.com/ig/api?weather=Chicago"; NSString *request = [NSString stringWithFormat:@"%@",address]; NSLog(@"request: %@", request); NSURL *URL = [NSURL URLWithString:request]; NSError *error; NSString *XML = [NSString stringWithContentsOfURL:URL encoding:NSASCIIStringEncoding error:&error]; NSLog(@"XML: %@", XML); NSLog(@"XML lenght: %d", [XML length]); As of yesterday Aug 25th, 2012 I get absolutely nothing back! I don't get any results back. When did this happen?