weatherdata via google

I needed weather data on a wordpress page and all the plugins I found were not flexible enough for my needs. Then I discovered by accident the google weather API, which was basically just what I needed, but unfortunately there doesn’t seem to be an official documentation. Thankfully I discovered the Web-Spirit page (in german), which explains the whole thing thoroughly, including examples and a great function to call the google API. There is a problem when trying to get the weather for an austrian city, but the solution is pretty simple:

$wetter =website_wetter("", "Austria", "de", "Linz");

And it works!

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.