Get Weather Widget

I’ve written a Widget plugin for the Get Weather plugin.

In it’s initial version, it’s a bit simplistic. I aim to make it a bit more flexible as I get more familiar with the widget code and the Get Weather plugin itself. Note that if you don’t have the Get Weather plugin activated, the widget will automagically de-activate itself. (I think that’s the best way to handle it, let me know if you think otherwise.)

Control panel:

Get Weather widget control panel

Download here:

Older versions:

14 Responses to Get Weather Widget

  1. T.J. says:

    Widget works great. For some reason I couldn’t get “get weather” to pull the right city (international) when used by itself – but with the widget it works perfect! I was wondering if there is a way you can have it centered on the sidebar. For some reason I think it’d just look better that way.

  2. Your did a *great* job – thanks .
    I run your widget under WordPressMU, so every user will have their hometown weather.
    The only enhancement could be language localisation,
    maybe in version 0.2 ……

  3. stormerider says:

    The only enhancement could be language localisation,
    maybe in version 0.2 ……

    The plugin itself doesn’t support localization, so neither does the widget. I do plan to expand the widget to more easily control the features of the plugin, but I don’t intend to alter the plugin itself.

    Ask Jeff Minard, the original author. :)

  4. Redhawk says:

    Hey, Storme!

    The site’s up but I haven’t had time to do a monster reprogramming, yet. In the meantime, I’ve been goofing with the widgets and downloading templates. Came across a problem with you Get-Weather widget!

    I have Akismet running (thank gods!) and when I try to activate the Get-Weather widget, not only does it not activate, but it deactivates both Akismet and Now-Reading . . .

    Hear of anybody else with this issue?

  5. Redhawk says:

    Erm . . . cancel that last. Doofus Redhawk should read the instructions that blatantly announce that the Get Weather plugin should be activated first. D’oh!

  6. stormerider says:

    Wierd… still only should have deactivated the widget, not anything else.

  7. Justin Moore says:

    For some reason, I can’t seem to get the plugin to activate. I’ve tried quite a few things – disabling Akismet as well as a few other plugins, but to no avail. Any suggestions? Currently, I have the following plugins activated:
    Akismet 1.15
    Category Replacement Widget 0.5
    Drop-down Archive Widget 0.2
    PHP Exec 1.5
    WWW Redirect 0.3
    Sidebar Widgets 1.0

  8. DangerMouse says:

    Hey, nice work, it worked from the scratch for me.

    Just a question: How can I add two of them for different cities in my sidebar?

  9. stormerider says:

    Hey, nice work, it worked from the scratch for me.

    Just a question: How can I add two of them for different cities in my sidebar?

    I don’t have support for multiple instances of the widget yet, but I’ll look into that.

  10. Ken says:

    Now one on Get Weather. The widget installs fine but I am clearly doing something wrong. Permissions seem okay

    Warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /home/ccai/html/blog/wp-content/plugins/getweather.php on line 122

    Warning: fopen(http://xoap.weather.com/weather/local/CAXX0343?cc=*&dayf=1&unit=s) [function.fopen]: failed to open stream: no suitable wrapper could be found in /home/ccai/html/blog/wp-content/plugins/getweather.php on line 122
    # Weather Not Available (Read Error)

    Any ideas appreciated.

  11. stormerider says:

    Now one on Get Weather. The widget installs fine but I am clearly doing something wrong. Permissions seem okay

    Warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /home/ccai/html/blog/wp-content/plugins/getweather.php on line 122

    Warning: fopen(http://xoap.weather.com/weather/local/CAXX0343?cc=*&dayf=1&unit=s) [function.fopen]: failed to open stream: no suitable wrapper could be found in /home/ccai/html/blog/wp-content/plugins/getweather.php on line 122
    # Weather Not Available (Read Error)

    Any ideas appreciated.

    That’s an error from the actual plugin, not the widget. However, what it’s saying is that your webhost has disabled URL file accesses. Basically Get Weather pulls the weather data over the web as if it were a local file. Your webhost has disallowed that option.

    There may be a way to work around it, but you’ll need to check into the actual plugin for that. If it’s a config variable I’ll update the widget to support it, but it’s not something in my code as it stands.

  12. Ken says:

    That’s an error from the actual plugin, not the widget. However, what it’s saying is that your webhost has disabled URL file accesses. Basically Get Weather pulls the weather data over the web as if it were a local file. Your webhost has disallowed that option.

    I suspected that might be it. At least I know it isn’t me. I will check and see if it can be allowed.

    There may be a way to work around it, but you’ll need to check into the actual plugin for that. If it’s a config variable I’ll update the widget to support it, but it’s not something in my code as it stands.

    That would certainly be great, if possible. With security an increasing concern, others may run into the same restriction.

    Thanks.

  13. Pingback: Wordpress Weather Widgets for Local Blogs | Top Blogger

  14. Pingback: Dellemente Net-Magazine - Where Web Technology Means Business.

Leave a Reply

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

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>