Yowindow Website shows NaN for pressure, not the value
Posted: Mon May 11, 2015 9:50 am
Already a considarable number of days most yowindow website gadgets display NaN " or NaN hPa for the barometric pressure.
I waited with investigating, hoping that it was temporary, but it is not, it is a feature.
A new parameter has been added, u_pressure_level with two possible values:
u_pressure_level: "sealevel",
or
u_pressure_level: "location",
As most of the world use the sea level pressure to compare places, most users have SLP (Sea Level Pressure) as data for Yowindow.
When adding this parameter, be aware that the documentation on http://yowindow.com/widget_parameters.php tells us that the SLP is coded as "sea"
But that does not seem to work. Only "sealevel" or "location" removes the NaN and displays the value form the yowindow.xml
The img explains what the it should look (right) and how not (left)
How to add the new param:
These are the two ways most often used:
1. direct html for yowidget3.swf
<param name="flashvars" value="location_id=gn:5128581&time_format=12& . . . . "
Add inside the list &u_pressure_level=sealevel;
2. swfobject.js javascript as interface to yowidget3.swf
Add the param to the list
var flashvars = {
lat: "50.85000",
. . .
u_pressure: "hpa",
u_pressure_level: "sealevel",
u_distance: "km",
Hope this cleans up a few displays, at least it did for some users of my template,
Wim
I waited with investigating, hoping that it was temporary, but it is not, it is a feature.
A new parameter has been added, u_pressure_level with two possible values:
u_pressure_level: "sealevel",
or
u_pressure_level: "location",
As most of the world use the sea level pressure to compare places, most users have SLP (Sea Level Pressure) as data for Yowindow.
When adding this parameter, be aware that the documentation on http://yowindow.com/widget_parameters.php tells us that the SLP is coded as "sea"
But that does not seem to work. Only "sealevel" or "location" removes the NaN and displays the value form the yowindow.xml
The img explains what the it should look (right) and how not (left)
How to add the new param:
These are the two ways most often used:
1. direct html for yowidget3.swf
<param name="flashvars" value="location_id=gn:5128581&time_format=12& . . . . "
Add inside the list &u_pressure_level=sealevel;
2. swfobject.js javascript as interface to yowidget3.swf
Add the param to the list
var flashvars = {
lat: "50.85000",
. . .
u_pressure: "hpa",
u_pressure_level: "sealevel",
u_distance: "km",
Hope this cleans up a few displays, at least it did for some users of my template,
Wim