WordPress UK Weather Observations Plugin
This is a WordPress plugin that displays recent local weather observations based on RSS feeds published by the BBC. Despite its name, it can be used for weather observations worldwide.
I wrote the plugin for one of the other web sites that I look after, but because we English are obsessed with our weather, I thought that I would make it generally available under the GNU General Public License.
The current version of the plugin is version 2.0 released on 9 July 2009.
Features
- Displays local weather information (worldwide, not just UK), updated regularly during daylight hours;
- Weather information is sourced from the BBC;
- Weather information is updated automatically;
- Admin interface to select locality and customize settings;
- WordPress Widget enabled;
- Written specifically for WordPress 2.7+;
- No PHP skills or file changes are required;
- And more!
Pricing and Licensing
The plugin is free! I have released it under the GNU General Public License so you can use it free of charge on your blog. You can also change (improve) it if you wish – if you do, please email the improvements to clive@clive-publishing.com so that I can consider them for incorporation into a future version.
Please note that the BBC impose some restrictions on the use of their feeds – see www.bbc.co.uk/weather/bbcweather/features/RSS_termsandconditions.shtml for more information.
Download
The plugin is kindly hosted by WordPress.
Installation
Download the ‘UK Weather Observations’ .zip archive and extract the directory/files into your wp‑content/plugins/ directory. Then go to your WordPress administration page, click on Plugins and activate it. See the Plugins section of the WordPress Codex for more information.
If you are updating from an earlier version, you can use the WordPress automatic upgrade facility in your blog’s dashboard.
You will then have a new sub-menu item called “UK Weather Observations” under the “Settings” menu. You can enter your BBC location code there. If you don’t enter a code, weather observations for Penzance, Cornwall (the closest location to the home of Clive Publishing) will be displayed.
To find your BBC location code, go to http://news.bbc.co.uk/weather/ and search for your nearest town or large village.
If the search is successful, your BBC location code is the one to four digit number in the middle of the URL. For example, if you search for ‘Penzance’, the search result URL is ‘http://news.bbc.co.uk/weather/forecast/2756?&search=penzance&itemsPerPage=10®ion=uk’ – the BBC location code is 2756. If the BBC location code is less than four digits add leading zeros, for example, for Oxford use 0025.
Alternatively, download the latest version of ‘BBC Weather Observations Codes‘ from the Clive Publishing website and search it for your nearest town or large village.
If the search is not successful, try the next nearest town or large village.
To display your weather information in a post or on a page simply type [ uk-wobs ] (no spaces) where you would like the information to appear.
If you would like to display the information in the sidebar you can use the plugin’s Widget.
If you wish to change the style of the information displayed, this can be done by making the relevant changes to your WordPress theme stylesheet; no changes to the code of the plugin are required.
Support
If you have comments, problems or suggestions or see something in the code which is not compliant with the WordPress Plugin Codex, please add a comment to this page, create a post at the WordPress support forum (tag it with “uk-weather-observations”) or send an email to clive@clive-publishing.com.
If you think you’ve found a bug, please send an email to clive@clive-publishing.com and I will do my best to fix it.
Donate
If you enjoy the plugin, you can thank me and leave a small donation for the time I’ve spent writing and supporting it.
Thank you for your support.
Supported by backstage.bbc.co.uk.




















