• I uploaded the weather plugin by Jeremiah. I’m just a newbie. The instructions say that after I have everything uploaded, just add the line <?php WeatherIcon(‘KLUF’,’Lufkin, Texas’) ?> to my index.php. Can someone tell me where I put that line in my index.php? I keep getting errors (btw, I changed the location and station info). I just don’t know where to put it in my index file without getting errors. Am I missing some steps here? The instructions make it seem to easy. Any help appreciated. Thanks in advance.

Viewing 15 replies - 1 through 15 (of 18 total)
  • What errors are you getting ? we need the error message really.
    PHP errors ?
    Plugin errors ?
    Validation errors ?

    Thread Starter Anonymous

    Fatal error: Call to undefined function: weathericon() in /hsphere/local/home/gtquandary.com/wordpress/index.php on line 6

    That would mean the plugin is not plugged in.

    Thread Starter Anonymous

    I think I found what I’m doing wrong, but I don’t know how to fix it. I don’t know how to write access on the cache folder. I think I have to edit this line:
    $cache_path = ‘/home/youruser/public_html/wordpress/wp-content/plugins/weather_cache’; // absolute path & no trailing slashes | make sure you set write access to this folder.
    Help? Thanks in advance again.

    Thread Starter Anonymous

    Beel, I appreciate the help. I’m a complete newbie with this stuff so bear with me. How do I activate weather.php? The reason I made my last post is because a part of the installation instructions says:
    “Then edit the weather.php file to point to the
    “wicons” folder and set the other options listed there.
    make sure you set write access on the cache folder.”
    I don’t know how to do this step, and after examining another person’s site, it seemed I was missing the step indicated in my last post. Namely, I didn’t edit the cache path to my own blog (which I don’t know what to write) and I don’t know how to “write access” to a folder.

    Well, you activate the plugin by placing weather.php in the plugins folder and go into the admin panel under plugins and press “Activate”. As for write access, that depends on your ftp program, but generally if you right click on the directory and select “Properties” you can set the access level that way.

    I have activated my weather icon, but get this error:

    Warning: fopen(/home/youruser/public_html/wordpress/wp-content/plugins/weather_cache/metar_cache_RJTJ.txt): failed to open stream: No such file or directory in /home/mi327/public_html/wp-content/plugins/weather.php on line 313
    # Conditions Debug

    what does this mean? I also think I need to edit my weather.php what do i write when it says icon location in the weather.php file? what is “your host” mean?

    I am having this same problem

    Question about changes to the weather.php file:

    Is it possible to use the following settings in the configuration instead of the hard-coded values:

    * get_settings(‘siteurl’) for $icon_location
    * ABSPATH for $cache_path

    Also, do I need to create the weather-cache folder or does he plugin do this for me?

    I don’t know, RaulTBC. Never tried it. If you set it up that way and it doesn’t work, you’ve answered your own question….

    As to the cache: depends on the version you’re using. The latest version (2.30) is found at https://www.viper007bond.com/wordpress-plugins/weathericon/. The latest version creates the cache for you, but you still must chmod to 777 to keep it from throwing errors. Older versions you usually had to make a cache folder according to where the path was looking for it.

    I’m on a Win2K3 server so I don’t do the chmod – but I can set CRUD on the folder… would that do?

    Um. I have absolutely NO clue, I don’t do win servers…. I would assume if you know what you’re doing with one that whatever you do to make a win server “equal” world-writeable in linux would suffice.

    I installed as-is and updated my station. Works great! Only thing I found was that even though my cache type is database, the Cache Path adds extra slashes in the File Path after I click to update the options.

    It first was e:\inetpub\wwwroot\mypath\wp-content/plugins/ … and after the update (changed checkbox values to display) it returned e:\\inetpub\\wwwroot\\mypath\\wp-content//plugins//… After another update? e:\\\inetpub\\\wwwroot\\\mypath\\\wp-content///plugins/// and so forth …

    It doesn’t impact because I have database cache but I thought I’d let you know…

    Hmm. Yup, that could be problematic for someone, and thanks so much for posting!

    If you download and install the WP-Dash plugin (https://somethingunpredictable.com/wp-dash/), you can use WeatherIcon with it too….

    I’ll look at that – being new to the whole PHP/Wordpress environment, I’m leary of changing too drastically …

    I also noticed that when I activated the plug-in, a script from a prior plug-in (democracy poll plugin) ran, which attempted to insert records into a democracy database table. Would there be something that activation does that could cause something like that? I have to find the support post for that plugin and let that author know.

    The only common thing between the two plugins is that it does something behind the scenes to add the plug-in option to the dashboard – yours is under “Options” and Democracy is under “Manage”.

Viewing 15 replies - 1 through 15 (of 18 total)
  • The topic ‘Help for weather plugin’ is closed to new replies.