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 4017) - 17 March 2024

Legacy Cumulus 1 release v1.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

Don't try to change "todayyest.html"

Share your Cumulus MX user interface here

Moderator: mcrossley

Post Reply
sfws
Posts: 1183
Joined: Fri 27 Jul 2012 11:29 am
Weather Station: Chas O, Maplin N96FY, N25FR
Operating System: rPi 3B+ with Buster (full)

Don't try to change "todayyest.html"

Post by sfws »

This is just a warning, after I tried to change the solar table on the today and yesterday page in the MX interface. The contents of the tables in the todayyest.html file will be seen as you first load the file, but the ajax routines quickly replaces whole tables to change their content. So there is absolutely no point in editing the HTML, other than to change the order of complete tables. Do not bother to edit what on that web page source file is within any table (to add, relabel, or remove, items).

Have a look at the tempTable below, It mentions High Temperature, but it does not mention Low Temperature yet both are being updated while you view the page. It includes two fixed times(23:10 and 15:10) but you don't see those fixed times on the page in the interface. In other words, ignore the structure within the <table> and </table> tags, it is overwritten by the Javascript.

In the HTML file

Code: Select all

<table id="TempTable" style="width:100%">
                        <thead>
                            <tr>
                                <th>&nbsp;Temperature</th>
                                <th></th>
                                <th></th>
                                <th></th>
                                <th></th>
                            </tr>
                            <tr>
                                <th>&nbsp;</th>
                                <th colspan="2">Today</th>
                                <th colspan="2">Yesterday</th>
                            </tr>
                        </thead>
                        <tr>
                            <td>High Temperature</td>
                            <td><span id="OutdoorTemp">--</span>&nbsp;<span class="TempUnit">--</span></td>
                            <td>23:10</td>
                            <td><span id="OutdoorTemp">--</span>&nbsp;<span class="TempUnit">--</span></td>
                            <td>15:10</td>
                        </tr>
                        <tr>
                            <td>Dew Point</td>
                            <td><span id="OutdoorDewpoint">--</span></td>
                            <td><span class="TempUnit">--</span></td>
                        </tr>
                        <tr>
                            <td>Wind Chill</td>
                            <td><span id="WindChill">--</span></td>
                            <td><span class="TempUnit">--</span></td>
                        </tr>
                        <tr>
                            <td>Apparent Temperature</td>
                            <td><span id="AppTemp">--</span></td>
                            <td><span class="TempUnit">--</span></td>
                        </tr>
                        <tr>
                            <td>Heat Index</td>
                            <td><span id="HeatIndex">--</span></td>
                            <td><span class="TempUnit">--</span></td>
                        </tr>
                        <tr>
                            <td>Humidex</td>
                            <td><span id="Humidex">--</span></td>
                            <td><span class="TempUnit">--</span></td>
                        </tr>
                        <tr>
                            <td>Indoor Temperature</td>
                            <td><span id="IndoorTemp">--</span></td>
                            <td><span class="TempUnit">--</span></td>
                        </tr>
                    </table>
The corresponding\CumulusMX\interface\js\todayyest.js file

Code: Select all

var tempTable = $('#TempTable').DataTable({
        "paging": false,
        "searching": false,
        "info": false,
        "ordering": false,
        "ajax": '../api/todayyest/temp.json'
    });
I don't know where the api json mentioned is, but it would be there that you would edit (if for example you wanted to show UV or did not want to see high and Low Apparent Temp).
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Don't try to change "todayyest.html"

Post by water01 »

I am sorry but I have to disagree. I have edited mine to remove the Solar parts and it worked fine.

Image

Not sure why your edits are not working but it maybe the same reason some of your Settings drop down items are not working?
David
Image
User avatar
mcrossley
Posts: 12689
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Don't try to change "todayyest.html"

Post by mcrossley »

The content of the tables is dynamically created from the downloaded data, so any changes you make to them will be lost - you need to fix the source data.

However, if you remove the table completely from the HTML it will not be created.
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Don't try to change "todayyest.html"

Post by water01 »

The JSON files can also be looked at in the browser. If you hit F12 and make sure that Network is selected and refresh the screen you will see the json files loaded at the end of the list. In Firefox if you double click on the json line it opens a property window where it shows you the URL of json file created by the CumulusMX engine.
If you cut and paste that URL into separate tab/window this is what you get (temp as an example).
Image
David
Image
sfws
Posts: 1183
Joined: Fri 27 Jul 2012 11:29 am
Weather Station: Chas O, Maplin N96FY, N25FR
Operating System: rPi 3B+ with Buster (full)

Re: Don't try to change "todayyest.html"

Post by sfws »

mcrossley wrote: Mon 23 Mar 2020 11:15 am The content of the tables is dynamically created
That is a neater way of describing it, although perhaps too technical for a few readers.

If I was developer, I would probably have just one row per table, and all table cells in the HTML empty, knowing that they would be replaced, particularly as number of cells by row, and number of rows both vary after dynamic creation.
water01 wrote: Mon 23 Mar 2020 10:36 am I have edited mine to remove the Solar parts and it worked fine
I did not say you could not remove a table, I said I could not edit the solar table to add UV, there is a difference.

I cannot see any image in your post, just the word image, your image has not been uploaded correctly.

The basic message remains true - that you cannot edit the table contents by changing the HTML file. I believe it a valid message to have in this forum where some readers are not as technically knowledgeable as others.
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Don't try to change "todayyest.html"

Post by water01 »

I cannot see any image in your post, just the word image, your image has not been uploaded correctly.
I suspect this is either a setting in your browser stopping images loading or a slow internet connection as the image was not loaded on Cumulus Support Forum but hosted on my server here http://www.dmjsystems.co.uk/djweather/tempjson.png
David
Image
freddie
Posts: 2434
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 22.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Re: Don't try to change "todayyest.html"

Post by freddie »

water01 wrote: Mon 23 Mar 2020 12:56 pm I suspect this is [...] a setting in your browser stopping images loading
No, it's a phpBB setting. If you want to include an image you need to upload it.
Freddie
Image
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Don't try to change "todayyest.html"

Post by water01 »

Surely not if you include it in img delimiters, that is how the banners work and also I can see the images in the post?
David
Image
User avatar
mcrossley
Posts: 12689
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Don't try to change "todayyest.html"

Post by mcrossley »

I see the image too?
User avatar
jimi
Posts: 32
Joined: Sun 29 Sep 2013 11:06 am
Weather Station: Maplin N96GY/F. O. WH1081
Operating System: Windows 10 64bit
Location: Glenrothes: The Kingdom of Fife
Contact:

Re: Don't try to change "todayyest.html"

Post by jimi »

I can see the image as well, as below

Image

It is possible to disable the use of IMG tags globally in phpBB, it's default setting is "allowed" but it can be disabled in the ACP, via Permissions, IIRC
Last edited by jimi on Tue 24 Mar 2020 3:10 am, edited 3 times in total.
Black is not a colour ! .... Its the absence of colour
Image
User avatar
jimi
Posts: 32
Joined: Sun 29 Sep 2013 11:06 am
Weather Station: Maplin N96GY/F. O. WH1081
Operating System: Windows 10 64bit
Location: Glenrothes: The Kingdom of Fife
Contact:

Re: Don't try to change "todayyest.html"

Post by jimi »

Might be worth checking in your UCP on the "Board preferences/Edit display options" tab that the option to display images in posts is set to Yes.

EDIT
UCP = phpBB User Control Panel
Black is not a colour ! .... Its the absence of colour
Image
freddie
Posts: 2434
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 22.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Re: Don't try to change "todayyest.html"

Post by freddie »

water01 wrote: Mon 23 Mar 2020 3:30 pm Surely not if you include it in img delimiters, that is how the banners work and also I can see the images in the post?
mcrossley wrote: Mon 23 Mar 2020 3:40 pm I see the image too?
I was wrong. It was the avatars only that I prevent remote linking to. Images in posts are okay as it is easy to edit a post with a dead link. Apologies for misleading :D
Freddie
Image
freddie
Posts: 2434
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2 + Ecowitt
Operating System: GNU/Linux Ubuntu 22.04 LXC
Location: Alcaston, Shropshire, UK
Contact:

Re: Don't try to change "todayyest.html"

Post by freddie »

jimi wrote: Tue 24 Mar 2020 2:41 am Might be worth checking in your UCP on the "Board preferences/Edit display options" tab that the option to display images in posts is set to Yes.

EDIT
UCP = phpBB User Control Panel
NSS :lol:
Freddie
Image
User avatar
jimi
Posts: 32
Joined: Sun 29 Sep 2013 11:06 am
Weather Station: Maplin N96GY/F. O. WH1081
Operating System: Windows 10 64bit
Location: Glenrothes: The Kingdom of Fife
Contact:

Re: Don't try to change "todayyest.html"

Post by jimi »

freddie wrote: Tue 24 Mar 2020 5:14 am
jimi wrote: Tue 24 Mar 2020 2:41 am Might be worth checking in your UCP on the "Board preferences/Edit display options" tab that the option to display images in posts is set to Yes.

EDIT
UCP = phpBB User Control Panel
NSS :lol:
Wasn't intended for you, I never doubted you knew what it meant, which is why I didn't explain ACP In my previous post ;) However many users have no idea about the UCP and the settings in it 8-)
Black is not a colour ! .... Its the absence of colour
Image
Post Reply