Google Weather API gone?
问题 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]);