Spelhubben Weather

plugin banner

Weather widget & block with optional map and daily forecast. Can combine Open-Meteo, SMHI and Yr/MET data.

Author:Kenta Mattsson (profile at wordpress.org)
WordPress version required:6.9.4
WordPress version tested:6.9.4
Plugin version:2.0.4
Added to WordPress repository:02-10-2025
Last updated:17-03-2026
Rating, %:0
Rated by:0
Plugin URI:
Total downloads:1 497
Active installs:10+
plugin download
Click to start download

This plugin displays current weather and an optional forecast. It can aggregate data from free global weather providers (Open-Meteo, SMHI, Yr/MET Norway, FMI, Open-Weathermap, and Weatherapi.com) and compute a simple consensus. Works worldwide with excellent coverage in Europe and beyond.

License

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

Full license text is included in the LICENSE file in the plugin root.

Feedback & Bug Reports

Feedback and bug reports can be posted here: https://github.com/K3NT4/spelhubben-weather/issues
For common questions see the FAQ: https://github.com/K3NT4/spelhubben-weather/blob/main/Docs/FAQ.md
For Roadmap: https://github.com/users/K3NT4/projects/2
License: GPLv3 or later
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Weather widget & block with optional map and daily forecast. Can combine Open-Meteo, SMHI, Yr/MET, FMI, Open-Weathermap, and Weatherapi.com data.

Translations

The plugin is fully translatable and includes built-in translations for Swedish (sv_SE) and Norwegian Bokmål (nb_NO).

How to translate the plugin

Option 1: Contribute to translate.wordpress.org (recommended)
– Visit translate.wordpress.org
– Select your language and add translations via the browser interface
– Your translations will automatically be included in future releases

Option 2: Local translation files
If you need to add or modify translations locally:

  1. Generate or update the POT file (translation template):
    wp i18n make-pot . languages/spelhubben-weather.pot --slug=spelhubben-weather

  2. Create a PO file for your language (e.g., spelhubben-weather-de_DE.po):

    • Copy the .pot file and rename to match your locale (e.g., de_DE)
    • Use a translation tool like Poedit or a text editor
    • Translate all strings in the PO file
    • Save the file as spelhubben-weather-de_DE.po
  3. Generate the MO file (compiled binary format):
    msgfmt spelhubben-weather-de_DE.po -o spelhubben-weather-de_DE.mo

  4. Place files in the plugin:

    • Store both .po and .mo files in /languages/
    • Also generate a .l10n.php file (WordPress 6.0+):
      wp i18n make-json languages/spelhubben-weather-de_DE.po --no-purge
  5. Activate your translation:

    • Change your WordPress language to match the locale code (Settings General Site Language)
    • The plugin will automatically load the translated strings

Translation file structure:
languages/
spelhubben-weather.pot (template for all translations)
spelhubben-weather-sv_SE.po (Swedish source text)
spelhubben-weather-sv_SE.mo (Swedish compiled)
spelhubben-weather-sv_SE.l10n.php
spelhubben-weather-nb_NO.po (Norwegian source text)
spelhubben-weather-nb_NO.mo (Norwegian compiled)
spelhubben-weather-nb_NO.l10n.php

What gets translated:
– All frontend strings (shortcode output, widget labels, weather descriptions, WMO codes)
– Admin settings and UI labels
– JavaScript strings (expand/collapse, status messages)
– Error messages and notices

Best practices:
– Use context clues in the POT file (msgctxt) to distinguish similar phrases
– Test your translation in WordPress to ensure formatting and plurals work correctly
– Check that translated UI aligns properly in your language (RTL vs LTR)


Screenshots
FAQ
ChangeLog