A simple plugin to add an API-driven weather widget in the WordPress Dashboard. It uses the Guzzle HTTP client to fetch an API endpoint and formats the result inside the custom widget.
- Register for an API key at https://openweathermap.org/api
- Download and install the plugin into
wp-content/plugins
directory - Run
composer install
inside the plugin folder. This will download and install the dependencies insidecomposer.json
- Enter your API Key from Open Weather Map and put it in the
APPID
section where it says'APPID' => 'YOUR_API_KEY'
- Change the city to your preferred city in the
q
parameter - currently set to'q' => 'Bristol,uk',
- The weather icons are designed by Alessio Atzeni and made freely at http://www.alessioatzeni.com/meteocons/
- Icons converted using IcoMoon