This causes errors from code in line 986 and 1175 in file yr_verdata.module.
All places with "[Cc]elcius" in yr_verdata.admin.inc (line 40, 41, 156) and yr_verdata.module (line 983, 1162, 1164, 1169, 1170, 1175 and 1183) must be changed to "[Cc]elsius".
After modification, setup for Yr Weatherdata must be updated to set correct value for temperature unit.

Comments

achilleas01’s picture

thanks for the solution about the 'celsius' change...but there is a problem with weather icons that do not appear at all!!! the problem is at function
function theme_yr_verdata_symbol($vars) {
that can not provide the correct URL to icons that are located in the page
http://symbol.yr.no/grafikk/sym/b38/
a quick change that i have made in order to have icons appear again was:
function theme_yr_verdata_symbol($vars) {
switch ($vars['number']) {
case 1:
case 2:
case 3:
case 5:
case 6:
case 7:
case 8:
$url = 'http://symbol.yr.no/grafikk/sym/b38/0' . $vars['number'] . 'd.png';
break;
case 4:
$url = 'http://symbol.yr.no/grafikk/sym/b38/0' . $vars['number'] . '.png';
break;
default:
$url = 'http://symbol.yr.no/grafikk/sym/b38/' . $vars['number'] . '.png';
}

return theme('image', $url, $vars['name'], $vars['name'], NULL, FALSE);
}
but this does not take in account the time of the day in order to show the day icon or the night icon...
i am waiting for a better solution

reswild’s picture

Looks like you are missing case 9 in the code above.
I think it should be:

case 4:
case 9:
$url = 'http://symbol.yr.no/grafikk/sym/b38/0' . $vars['number'] . '.png';
break;

Anonymous’s picture

I have the same issues.
Yesterday it just stopped workin.
I fixed the error generated by the spell
but I tried the above code for the images but it did'nt work.

tjodolv’s picture

Assigned: Unassigned » tjodolv

Hello there. I will take a look at this later this week. Thanks for the feedback!
It seems that yr.no changed their XML feeds, but I did not get notified, even though I signed up for their "developer mailing list". I'm working on a fix right now, and will ask them to change the feed back to the format they used the last year, because it required a lot less code to manage.

Anonymous’s picture

Cool!
Please keep us updated!

tjodolv’s picture

Version: 7.x-1.1 » 7.x-1.x-dev
Priority: Major » Critical

Committed to dev. Pushing an update tonight after testing on one more server, because this is actually a critical issue.

tjodolv’s picture

This should now work with the new releases 6.x-2.2 and 7.x-1.2 (skipped 6.x-2.1 for keeping the modules' release tags synced).

Please report any problems, and I'll work on them as soon as I can.

Anonymous’s picture

It works perfectly!
Thank you!

tjodolv’s picture

Status: Active » Fixed

This appears to be fixed :)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.