Welcome to the Cumulus Support forum.
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
Temp Arrow won't display?
Moderator: saratogaWX
- William Grimsley
- Posts: 833
- Joined: Thu 22 Sep 2011 5:22 pm
- Weather Station: Davis Vantage Vue
- Operating System: Windows 7 Home Premium 64-bit
- Location: Latitude: 50.70189285 Longitude: -3.30849957
- Contact:
Temp Arrow won't display?
Hi there,
For some reason, the ajax temp arrow won't display on my ajax-dashboard.php file! I haven't altered the ajaxCUwx.js in any way, so I don't know how this has happened? On a side note, the ajax temp arrow does display using Javascript!
This seems very strange and I don't know how to fix it!
Please can someone help?
Thanks,
William
For some reason, the ajax temp arrow won't display on my ajax-dashboard.php file! I haven't altered the ajaxCUwx.js in any way, so I don't know how this has happened? On a side note, the ajax temp arrow does display using Javascript!
This seems very strange and I don't know how to fix it!
Please can someone help?
Thanks,
William
- saratogaWX
- Posts: 1185
- Joined: Wed 06 May 2009 5:02 am
- Weather Station: Davis Vantage Pro Plus
- Operating System: Windows 10 Professional
- Location: Saratoga, CA, USA
- Contact:
Re: Temp Arrow won't display?
Hmmm. I see the down-arrow under the big temperature in the ajax-dashboard area with no JavaScript enabled.
To isolate the problem to PHP or JavaScript, which of the following describes the problem you are seeing:
1) arrow DOES NOT appear when page is first loaded, then appears after the AJAX update is done
2) arrow DOES appear when page is first loaded, then disappears after the AJAX update is done
3) arrow DOES NOT appear when page is first loaded, and DOES NOT appear after the AJAX update is done
If (1) then the PHP data for temperature 1 hour ago matches the current temperature in CUtags.php, and the realtime.txt has a more current temperature which is different than the realtime value for 1 hour ago temperature. This is not a bug -- it's the way it works based on the 5-minute update sample in CUtags.php versus the every-few-seconds update in realtime.txt
If (2) it is also not a bug .. the 5-minute ago data had the two temperatures not matching (so an arrow is shown), while the realtime data shows that more recent data has the two temperatures matching, so no arrow is shown.
If (3) is also not a bug. It just means that both the 5-minute ago and the realtime temperatures do not have a difference to display, so no arrow.
To isolate the problem to PHP or JavaScript, which of the following describes the problem you are seeing:
1) arrow DOES NOT appear when page is first loaded, then appears after the AJAX update is done
2) arrow DOES appear when page is first loaded, then disappears after the AJAX update is done
3) arrow DOES NOT appear when page is first loaded, and DOES NOT appear after the AJAX update is done
If (1) then the PHP data for temperature 1 hour ago matches the current temperature in CUtags.php, and the realtime.txt has a more current temperature which is different than the realtime value for 1 hour ago temperature. This is not a bug -- it's the way it works based on the 5-minute update sample in CUtags.php versus the every-few-seconds update in realtime.txt
If (2) it is also not a bug .. the 5-minute ago data had the two temperatures not matching (so an arrow is shown), while the realtime data shows that more recent data has the two temperatures matching, so no arrow is shown.
If (3) is also not a bug. It just means that both the 5-minute ago and the realtime temperatures do not have a difference to display, so no arrow.
- William Grimsley
- Posts: 833
- Joined: Thu 22 Sep 2011 5:22 pm
- Weather Station: Davis Vantage Vue
- Operating System: Windows 7 Home Premium 64-bit
- Location: Latitude: 50.70189285 Longitude: -3.30849957
- Contact:
Re: Temp Arrow won't display?
Hi Ken,
My problem is 3)
The arrow will not display, like I said. But, there was a temperature difference at the time (in Cumulus), which was -0.5C.
Thanks,
William
My problem is 3)
The arrow will not display, like I said. But, there was a temperature difference at the time (in Cumulus), which was -0.5C.
Thanks,
William
- saratogaWX
- Posts: 1185
- Joined: Wed 06 May 2009 5:02 am
- Weather Station: Davis Vantage Pro Plus
- Operating System: Windows 10 Professional
- Location: Saratoga, CA, USA
- Contact:
Re: Temp Arrow won't display?
Actually, your problem is (2) (arrow appears when first loaded, then disappears when AJAX updates the page), so it is a JavaScript issue.
Looking at your page with Firefox and JavaScript enabled, I see the arrow does disappear.
The basic PHP generates this HTML with your CUtags.php values so the up-arrow image is there when the page first loads.
The ajaxCUwx.js has to refresh the arrow (or remove it) based on the realtime.txt fields 2(current temp), 25(temperature trend).
Your realtime.txt has those fields as 5.5 and 8.4 respectively.
Using Firefox Web Developer View Generated Source shows
I did a compare of the 'stock' ajaxCUwx.js and your current copy, and found over 30 differences where you have 'tweaked' the code (outside the normal settings area, but not in that specific area). I am unable to reproduce the problem with my Cumulus setup and the stock ajaxCUwx.js so all I can say is:
1) yes, you have a JavaScript (not a PHP) issue.
2) it is in your ajaxCUwx.js
3) since I cannot reproduce the effect on my own setup, I can't do any more diagnosis for you.
Regrets,
Ken
Looking at your page with Firefox and JavaScript enabled, I see the arrow does disappear.
The basic PHP generates this HTML with your CUtags.php values
Code: Select all
<span class="ajax" id="ajaxtemparrow"><img src="./ajax-images/rising.gif" alt="Increased 0.2°C than last hour." title="Increased 0.2°C than last hour." width="7" height="8" style="border: 0; margin: 1px 3px;" /></span>
The ajaxCUwx.js has
Code: Select all
var temp = convertTemp(realtime[2]);
...
var temptrend = convertTempRate(realtime[25]);
var temparrow = ajax_genarrow(temp, temp-temptrend, '',
langTempRising+uomTemp+langTempLastHour,
langTempFalling+uomTemp+langTempLastHour,1)
Your realtime.txt has those fields as 5.5 and 8.4 respectively.
Using Firefox Web Developer View Generated Source shows
so the issue is a JavaScript one.<span style="" lastobs=" " class="ajax" id="ajaxtemparrow"> </span>
I did a compare of the 'stock' ajaxCUwx.js and your current copy, and found over 30 differences where you have 'tweaked' the code (outside the normal settings area, but not in that specific area). I am unable to reproduce the problem with my Cumulus setup and the stock ajaxCUwx.js so all I can say is:
1) yes, you have a JavaScript (not a PHP) issue.
2) it is in your ajaxCUwx.js
3) since I cannot reproduce the effect on my own setup, I can't do any more diagnosis for you.
Regrets,
Ken
- William Grimsley
- Posts: 833
- Joined: Thu 22 Sep 2011 5:22 pm
- Weather Station: Davis Vantage Vue
- Operating System: Windows 7 Home Premium 64-bit
- Location: Latitude: 50.70189285 Longitude: -3.30849957
- Contact:
Re: Temp Arrow won't display?
Hi Ken,
Thanks for your explanation.
Thanks,
William
Thanks for your explanation.
Ok, I just replaced my ajaxCUwx.js file and the problem still lies, so how can the problem be in the ajaxCUwx.js file?saratogaWX wrote:I did a compare of the 'stock' ajaxCUwx.js and your current copy, and found over 30 differences where you have 'tweaked' the code (outside the normal settings area, but not in that specific area). I am unable to reproduce the problem with my Cumulus setup and the stock ajaxCUwx.js so all I can say is:
1) yes, you have a JavaScript (not a PHP) issue.
2) it is in your ajaxCUwx.js
3) since I cannot reproduce the effect on my own setup, I can't do any more diagnosis for you.
Thanks,
William
- saratogaWX
- Posts: 1185
- Joined: Wed 06 May 2009 5:02 am
- Weather Station: Davis Vantage Pro Plus
- Operating System: Windows 10 Professional
- Location: Saratoga, CA, USA
- Contact:
Re: Temp Arrow won't display?
I really wish you'd cease using
for your emoticon -- it's really unnecessary and it feels like you are trying to bash those who attempt to assist you.
Perhaps or would be a better indicator of your current state. The rest of us will continue to use or based on your questions.
Now to the problem at hand. The reason the JavaScript fails to produce an arrow is that your realtime.txt is not emitting a temperature change value where it should normally exist.
I substituted '|' for the normal blank delimiter so you can see so therefore, no arrow is being produced. The JavaScript code in ajaxCUwx.js is working correctly.. it's the realtime.txt that seems to have the issue with a null-content temperature trending value.
I know you've had other postings about installation/re-installation issues .. maybe something happened there that is causing your realtime.txt file to be slightly malformed, and that is causing the display issue you are seeing.
for your emoticon -- it's really unnecessary and it feels like you are trying to bash those who attempt to assist you.
Perhaps or would be a better indicator of your current state. The rest of us will continue to use or based on your questions.
Now to the problem at hand. The reason the JavaScript fails to produce an arrow is that your realtime.txt is not emitting a temperature change value where it should normally exist.
I substituted '|' for the normal blank delimiter so you can see
note the null field in position 25 which is where the temperature difference should be. Since a null is also interpreted as a zero, there is no change detected in the statement6/03/2013|21:52:23|3.4|92%|2.2|1.0|1.0|225|0.0|7.8|992.05|SW|1|mph|C|hPa|mm|170.9|0.54|43.0|189.6|11.2|21.7|43|3.4||8.4|15:04|3.4|21:46|18.0|01:27| ...
Code: Select all
var temparrow = ajax_genarrow(temp, temp-temptrend, '',
langTempRising+uomTemp+langTempLastHour,
langTempFalling+uomTemp+langTempLastHour,1)
I know you've had other postings about installation/re-installation issues .. maybe something happened there that is causing your realtime.txt file to be slightly malformed, and that is causing the display issue you are seeing.
- steve
- Cumulus Author
- Posts: 26701
- Joined: Mon 02 Jun 2008 6:49 pm
- Weather Station: None
- Operating System: None
- Location: Vienne, France
- Contact:
Re: Temp Arrow won't display?
That's not the standard realtime.txt file, so it's presumably made up from web tags. The wiki entry for realtime.txt incorrectly said that the web tag for the temperature trend value is <#temptrendval> when in fact it's <#temptrend>. I suspect that was my mistake, apologies. I've corrected the wiki.
Steve
- saratogaWX
- Posts: 1185
- Joined: Wed 06 May 2009 5:02 am
- Weather Station: Davis Vantage Pro Plus
- Operating System: Windows 10 Professional
- Location: Saratoga, CA, USA
- Contact:
Re: Temp Arrow won't display?
Thanks Steve!
Yes, that is likely the cause as I'm using the built-in realtime.txt and it's working fine on two different instances.
William should replace his template for realtime.txt (or switch to using the built-in one instead).
Best regards,
Ken
Yes, that is likely the cause as I'm using the built-in realtime.txt and it's working fine on two different instances.
William should replace his template for realtime.txt (or switch to using the built-in one instead).
Best regards,
Ken
- William Grimsley
- Posts: 833
- Joined: Thu 22 Sep 2011 5:22 pm
- Weather Station: Davis Vantage Vue
- Operating System: Windows 7 Home Premium 64-bit
- Location: Latitude: 50.70189285 Longitude: -3.30849957
- Contact:
Re: Temp Arrow won't display?
Thanks guys!
I've just changed the web tag <#temptrendval> to <#temptrend> and now the ajax temp arrow, displays!
Thanks very much for your help,
William
I've just changed the web tag <#temptrendval> to <#temptrend> and now the ajax temp arrow, displays!
Sorry, that emotion I'm not trying to aim at you, that's me getting angry!saratogaWX wrote:I really wish you'd cease using
Ok, I will use those emotion icons, from now on!saratogaWX wrote:Perhaps or would be a better indicator of your current state. The rest of us will continue to use or based on your questions.
Thanks very much for your help,
William