The Google Weather API only supports queries using postal codes in the United States, such as:
http://www.google.com/ig/api?hl=zh-cn&weather=94043
(94043 for Mountain View, CA zip code, USA)
It is necessary to use latitude coordinates as a parameter in addition to the United States to execute the Google Weather API, for example:
http://www.google.com/ig/api?hl=zh-cn&weather=,,, 30670000,104019996
(30670000,104019996 for Chengdu, the latitude and longitude coordinates of Chinese mainland)
Of course, may also pass the name of the city of Hanyu Pinyin to query, for example: The following is the weather in Beijing
Http://www.google.com/ig/api?weather=Beijing
to other areas of latitude and longitude coordinates, can be provided through the Google API country code list and the corresponding city latitude and longitude coordinates list can be queried, the following is the Google API provides query parameters:
Http://www.google.com/ig/countries?output=xml&hl=zh-cn
(Check the code of all countries supported by Google and show it in zh Simplified Chinese)
Http://www.google.com/ig/cities?output=xml&hl=zh-cn&country=cn
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.