Need help removing plots from web page display

63 views
Skip to first unread message

michael form

unread,
Apr 25, 2020, 2:11:56 PM4/25/20
to weewx-user
I will admit that I am a novice when it comes to Linux, but I have searched and followed directions in posts regarding the removal of plots from the web page that weewx displays. Weewx is running nicely on a Raspberry Pi 3 but when I look at the generated web page it includes things like WIND SPEED and WIND DIRECTION that I do not need or want in my application. 

In SKINS.CONF I have commented out [[[daywind]]] and its entry, [[[daywinddir]]] and its entries and [[[daywindvec]]] and its entries. 
In /etc/weewx/skins/Seasons/index.html.tmp1 I have commented out  the following lines: img src="daywindirection.png, , and img src="daywindvec.png,. 

However, after doing this, plots of Wind Speed, Wind Direction and Wind Vector still are showing up on the generated web page. Any suggestions on what I am doing wrong and how best to remove plots that I do not need?

Thank you.

John Kline

unread,
Apr 25, 2020, 2:22:11 PM4/25/20
to michael form, weewx-user
My guess is that you are seeing old plots. Comment out the corresponding lines in index.html.tmpl.

<!—
<img src="daywinddir.png" alt="$obs.label.windDir" />
<img src="daywindvec.png" alt="$obs.label.windvec" />
—>

> On Apr 25, 2020, at 11:12 AM, michael form <mike...@gmail.com> wrote:
>

John Kline

unread,
Apr 25, 2020, 2:23:17 PM4/25/20
to michael form, weewx-user
Oops, I didn’t include all of the plots. And I also didn’t mention that you need to do it for day, week, month and year (if that is what you want).

John Kline

unread,
Apr 25, 2020, 2:25:51 PM4/25/20
to weewx...@googlegroups.com
I see that you have said you already changed index.html.tmpl.  What does your entry for the SeasonsReport look like in weewx.conf?

On Apr 25, 2020, at 11:12 AM, michael form <mike...@gmail.com> wrote:


--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/c44be4b6-db70-47db-885a-77b9fd1b354a%40googlegroups.com.

michael form

unread,
Apr 25, 2020, 2:32:01 PM4/25/20
to weewx-user
I did comment out:
            <img src="daywinddir.png"   alt="$obs.label.windDir" />                                                                                                      
            <img src="daywindvec.png"   alt="$obs.label.windvec" />
            <img src="daywind.png"      alt="$obs.label.windSpeed" />

but the plots still show up.in DAY. Do I need to do this for week, month and year as well as day to make the plots disappear in "Day"?

Thanks for your quick response.

michael form

unread,
Apr 25, 2020, 5:12:45 PM4/25/20
to weewx-user
Here it is:


 [[SeasonsReport]]
        # The SeasonsReport uses the 'Seasons' skin, which contains the
        # images, templates and plots for the report.
        skin = Seasons
        enable = true


On Saturday, April 25, 2020 at 2:25:51 PM UTC-4, John Kline wrote:
I see that you have said you already changed index.html.tmpl.  What does your entry for the SeasonsReport look like in weewx.conf?

On Apr 25, 2020, at 11:12 AM, michael form <mike...@gmail.com> wrote:


I will admit that I am a novice when it comes to Linux, but I have searched and followed directions in posts regarding the removal of plots from the web page that weewx displays. Weewx is running nicely on a Raspberry Pi 3 but when I look at the generated web page it includes things like WIND SPEED and WIND DIRECTION that I do not need or want in my application. 

In SKINS.CONF I have commented out [[[daywind]]] and its entry, [[[daywinddir]]] and its entries and [[[daywindvec]]] and its entries. 
In /etc/weewx/skins/Seasons/index.html.tmp1 I have commented out  the following lines: img src="daywindirection.png, , and img src="daywindvec.png,. 

However, after doing this, plots of Wind Speed, Wind Direction and Wind Vector still are showing up on the generated web page. Any suggestions on what I am doing wrong and how best to remove plots that I do not need?

Thank you.

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx...@googlegroups.com.

John Kline

unread,
Apr 25, 2020, 5:55:26 PM4/25/20
to weewx...@googlegroups.com
It could be that you broke something when editing index.html.tmpl.  If you did, you would see errors in the log and public_html/index.html would never be regenerated.

What the date on public_html/index.html?

Do something like:
ls -l /home/weewx/public_html/index.html

On Apr 25, 2020, at 2:12 PM, michael form <mike...@gmail.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/d1826114-ce60-4b41-8f50-5260c55fdf6b%40googlegroups.com.

David Barto

unread,
Apr 25, 2020, 7:52:17 PM4/25/20
to weewx...@googlegroups.com

On Apr 25, 2020, at 2:55 PM, John Kline <jo...@johnkline.com> wrote:

It could be that you broke something when editing index.html.tmpl.  If you did, you would see errors in the log and public_html/index.html would never be regenerated.

What the date on public_html/index.html?

Do something like:
ls -l /home/weewx/public_html/index.html


My main page is getting updated just fine, that doesn’t seem to be an issue.

David

John Kline

unread,
Apr 25, 2020, 7:55:02 PM4/25/20
to weewx...@googlegroups.com
I’m looking for a date index.html.  Just because the graphs are being updated doesn’t mean the page is being regenerated.

Your symptoms would indicate that the page is failing to be regenerated.  The old page would still show the latest graphs.

Humor me with the ls output.

On Apr 25, 2020, at 4:52 PM, David Barto <ba...@kdbarto.org> wrote:



David Barto

unread,
Apr 25, 2020, 7:59:38 PM4/25/20
to weewx...@googlegroups.com
On Apr 25, 2020, at 4:54 PM, John Kline <jo...@johnkline.com> wrote:

I’m looking for a date index.html.  Just because the graphs are being updated doesn’t mean the page is being regenerated.

Your symptoms would indicate that the page is failing to be regenerated.  The old page would still show the latest graphs.

Humor me with the ls output.


Magrathea:weewx-installed katherinebarto$ ls -l public_html/index.html
-rw-r--r--  1 root  wheel  27784 Apr 25 16:58 public_html/index.html
Magrathea:weewx-installed katherinebarto$ date
Sat Apr 25 16:58:58 PDT 2020


gjr80

unread,
Apr 25, 2020, 8:18:19 PM4/25/20
to weewx-user
I take it you have cleared your browser cache....

Gary


--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx...@googlegroups.com.


--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx...@googlegroups.com.

michael form

unread,
Apr 25, 2020, 9:21:16 PM4/25/20
to weewx-user
Here is last output from /var/log:

Apr 25 21:04:54 raspberrypirpi3housetemp weewx[3470]: imagegenerator: Generated 11 images for SeasonsReport in 1.79 seconds
Apr 25 21:04:54 raspberrypirpi3housetemp weewx[3470]: copygenerator: copied 0 files to /var/www/html/weewx
Apr 25 21:05:37 raspberrypirpi3housetemp weewx[3470]: manager: Added record 2020-04-25 21:05:00 EDT (1587863100) to database 'weewx.sdb'
Apr 25 21:05:37 raspberrypirpi3housetemp weewx[3470]: manager: Added record 2020-04-25 21:05:00 EDT (1587863100) to daily summary in 'weewx.sdb'
Apr 25 21:05:50 raspberrypirpi3housetemp weewx[3470]: cheetahgenerator: Generated 8 files for report SeasonsReport in 1.14 seconds
Apr 25 21:05:51 raspberrypirpi3housetemp weewx[3470]: imagegenerator: Generated 11 images for SeasonsReport in 1.82 seconds
Apr 25 21:05:51 raspberrypirpi3housetemp weewx[3470]: copygenerator: copied 0 files to /var/www/html/weewx

Maybe I misinterpret this but it seems like the image plots are being copied.

Any ideas?

I appreciate all of the help that I have gotten here. If I knew much about Linux, I would be happy to share my knowledge as well. But, alas, I am 
a receiver, not a giver. 

John Kline

unread,
Apr 25, 2020, 9:30:30 PM4/25/20
to weewx...@googlegroups.com
Even if the plots are copied, you shouldn’t see them if index.html doesn’t have the img statements to display them.

How did you comment out the img statements?

Perhaps send the contents of image.html.tmpl and image.html.


On Apr 25, 2020, at 6:21 PM, michael form <mike...@gmail.com> wrote:

Here is last output from /var/log:
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/33eed829-7141-484d-9f3a-b8fcb5a1d4f6%40googlegroups.com.

michael form

unread,
Apr 25, 2020, 9:30:31 PM4/25/20
to weewx-user
Yes. I have cleared the browser cache. 

Where do I find " public_html/index.html" on a Debian install? 

Thanks.

John Kline

unread,
Apr 25, 2020, 9:34:39 PM4/25/20
to weewx...@googlegroups.com


On Apr 25, 2020, at 6:30 PM, michael form <mike...@gmail.com> wrote:


Yes. I have cleared the browser cache. 

Where do I find " public_html/index.html" on a Debian install? 
I forget, but probably /var/weewx/public_html/index.html
If that doesn’t work, someone else will know (or I’ll look at the install code).
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/8e3aab4d-1c81-4143-bdf0-6fcc160cf0a7%40googlegroups.com.

gjr80

unread,
Apr 25, 2020, 9:48:32 PM4/25/20
to weewx-user
Where depends on the WeeWX install type. For a setup.py install you will find the directory public_html in /home/weewx. For a package install you won't find a directory named public_html, rather the default location for Cheetah generated output is  /var/www/html/weewx. Put another way, the WeeWX symbolic name HTML_ROOT refers to /home/weewx/public_html for a setup.py install and to /var/www/html/weewx for a package install. Refer to Where to find things in the User's Guide.

Gary

John Kline

unread,
Apr 25, 2020, 10:08:02 PM4/25/20
to weewx...@googlegroups.com
We still don’t know how he commented out the image statements.  For instance, if he used //, it would work out for him.


On Apr 25, 2020, at 6:48 PM, gjr80 <gjrod...@gmail.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/5c7e331b-9499-48f8-994a-8b3eece80f1f%40googlegroups.com.

gjr80

unread,
Apr 25, 2020, 10:12:28 PM4/25/20
to weewx-user
Yes, sounds like it's time to post the modified index.html.tmpl. In fact, to remove all doubt I would say post the output of this command:

$ cat /etc/weewx/skins/Seasons/index.html.tmpl

Gary

michael form

unread,
Apr 25, 2020, 10:23:30 PM4/25/20
to weewx-user
OK. 

ls -l /var/www/html/index.html

10710 Apr 18 19:44

which remains the same as time passes. So indeed, it looks like you are correct in that the page is not updated even though the plots change with variations
in sensor outputs (i.e. the temperature changes).

In /etc/weewx/skins/Seasons/index.html.tmpl I commented out the following with "#".

#            <img src="daywind.png"      alt="$obs.label.windSpeed" />
 #           <img src="daywinddir.png"   alt="$obs.label.windDir" />
#            <img src="daywindvec.png"   alt="$obs.label.windvec" />

Where have I gone astray? What needs to be done to have the page regenerated to display properly?

John Kline

unread,
Apr 25, 2020, 10:25:17 PM4/25/20
to weewx...@googlegroups.com
I much appreciate that you did the ls -l.

Now we need the contents of index.html.tmpl


On Apr 25, 2020, at 7:23 PM, michael form <mike...@gmail.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/41498fea-a7c6-4bfb-9a1d-05fd7b3d3b9d%40googlegroups.com.

John Kline

unread,
Apr 25, 2020, 10:25:59 PM4/25/20
to weewx...@googlegroups.com
Oh, change the #
To ##

On Apr 25, 2020, at 7:23 PM, michael form <mike...@gmail.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/41498fea-a7c6-4bfb-9a1d-05fd7b3d3b9d%40googlegroups.com.

John Kline

unread,
Apr 25, 2020, 10:26:28 PM4/25/20
to weewx...@googlegroups.com
# is cheetah
## is a comment

On Apr 25, 2020, at 7:25 PM, John Kline <jo...@johnkline.com> wrote:



michael form

unread,
Apr 25, 2020, 10:47:44 PM4/25/20
to weewx-user
Well, I mentioned that I am a Linux novice. I usually design embedded hardware systems. :)

I changed it to ## and still no difference.

Here is the first part of /etc/weewx/skins/Seasons/index/html/tmpl dealing with daily images: I did not include the weekly and monthly info below.

## Copyright 2009-2018 Tom Keffer, Matthew Wall
## Distributed under terms of GPLv3.  See LICENSE.txt for your rights.
#errorCatcher Echo
##
## Specifying an encoding of UTF-8 is usually safe:
#encoding UTF-8
##
<!DOCTYPE html>
<html lang="en">
  <head>
    ## This choice should match the #encoding directive above
    <meta charset="UTF-8">
    <title>$station.location</title>
    <link rel="icon" type="image/png" href="favicon.ico" />
    <link rel="stylesheet" type="text/css" href="seasons.css"/>
    <script src="seasons.js"></script>
  </head>

  <body onload="setup();">
    #include "titlebar.inc"
    
    <div id="contents">
      <div id="widget_group">
        #include "current.inc"
        #include "sunmoon.inc"
        #include "hilo.inc"
        #include "sensors.inc"
        #include "about.inc"
        #include "radar.inc"
        #include "satellite.inc"
        #include "map.inc"
      </div>

      <div id="plot_group">
        <div id="history_widget" class="widget">
          <div id="plot_title" class="widget_title">History:&nbsp;&nbsp;
            <a class="button_selected" id="button_history_day"
               onclick="choose_history('day')">Day</a>
            <a class="button" id="button_history_week"
               onclick="choose_history('week')">Week</a>
            <a class="button" id="button_history_month"
               onclick="choose_history('month')">Month</a>
            <a class="button" id="button_history_year"
               onclick="choose_history('year')">Year</a>
          </div>
          <div id="history_day" class="plot_container">
            <img src="daybarometer.png" alt="$obs.label.barometer"/>
            <img src="daytempdew.png"   alt="$obs.label.outTemp" />
            <img src="daytempfeel.png"  alt="$obs.label.feel" />
            <img src="dayhum.png"       alt="$obs.label.outHumidity" />
##            <img src="daywind.png"      alt="$obs.label.windSpeed" />
##            <img src="daywinddir.png"   alt="$obs.label.windDir" />
##            <img src="daywindvec.png"   alt="$obs.label.windvec" />
            <img src="dayrain.png"      alt="$obs.label.rain" />
            #if $day.UV.has_data
            <img src="dayuv.png"        alt="$obs.label.UV" />
            #end if
            #if $day.radiation.has_data
            <img src="dayradiation.png" alt="$obs.label.radiation" />
            #end if
            #if $day.inTemp.has_data
            <img src="daytempin.png"    alt="$obs.label.inTemp" />
            #end if
            #if $day.extraTemp1.has_data or $day.extraTemp2.has_data or $day.extraTemp3.has_data
            <img src="daytemp.png"      alt="$obs.label.extraTemp1" />
            #end if
            #if $day.rxCheckPercent.has_data
            <img src="dayrx.png"        alt="$obs.label.rxCheckPercent"/>
            #end if

John Kline

unread,
Apr 25, 2020, 10:58:32 PM4/25/20
to weewx...@googlegroups.com
Are you sure you don’t have more of those single # around.  Like for the week, month and year?

Also, please verify each time you try something that index.html is still not being written by checking the date with ls -l.  (And, of course, wait for an archive cycle.)

Lastly, for sure there must be errors in the log for this.

On Apr 25, 2020, at 7:47 PM, michael form <mike...@gmail.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/2e965451-2e9d-42e2-b394-29fce4bb876f%40googlegroups.com.

John Kline

unread,
Apr 25, 2020, 11:00:18 PM4/25/20
to weewx...@googlegroups.com
And we still have the outstanding request for the whole index.html.tmp file.

On Apr 25, 2020, at 7:58 PM, John Kline <jo...@johnkline.com> wrote:



John Kline

unread,
Apr 25, 2020, 11:01:38 PM4/25/20
to weewx...@googlegroups.com
This is also your friend:


On Apr 25, 2020, at 8:00 PM, John Kline <jo...@johnkline.com> wrote:



michael form

unread,
Apr 25, 2020, 11:12:10 PM4/25/20
to weewx-user
Here is the complete index.html.tmpl file:

          </div>
          <div id="history_week" class="plot_container" style="display:none">
            <img src="weekbarometer.png" alt="$obs.label.barometer"/>
            <img src="weektempdew.png"   alt="$obs.label.outTemp" />
            <img src="weektempfeel.png"  alt="$obs.label.feel" />
            <img src="weekhum.png"       alt="$obs.label.outHumidity" />
            <img src="weekwind.png"      alt="$obs.label.windSpeed" />
            <img src="weekwinddir.png"   alt="$obs.label.windDir" />
            <img src="weekwindvec.png"   alt="$obs.label.windvec" />
            <img src="weekrain.png"      alt="$obs.label.rain" />
            #if $week.UV.has_data
            <img src="weekuv.png"        alt="$obs.label.UV" />
            #end if
            #if $week.radiation.has_data
            <img src="weekradiation.png" alt="$obs.label.radiation" />
            #end if
            #if $week.inTemp.has_data
            <img src="weektempin.png"    alt="$obs.label.inTemp" />
            #end if
            #if $week.extraTemp1.has_data or $week.extraTemp2.has_data or $week.extraTemp3.has_data
            <img src="weektemp.png"      alt="$obs.label.extraTemp1" />
            #end if
            #if $week.rxCheckPercent.has_data
            <img src="weekrx.png"        alt="$obs.label.rxCheckPercent"/>
            #end if
          </div>
          <div id="history_month" class="plot_container" style="display:none">
            <img src="monthbarometer.png" alt="$obs.label.barometer"/>
            <img src="monthtempdew.png"   alt="$obs.label.outTemp" />
            <img src="monthtempfeel.png"  alt="$obs.label.feel" />
            <img src="monthhum.png"       alt="$obs.label.outHumidity" />
            <img src="monthwind.png"      alt="$obs.label.windSpeed" />
            <img src="monthwinddir.png"   alt="$obs.label.windDir" />
            <img src="monthwindvec.png"   alt="$obs.label.windvec" />
            <img src="monthrain.png"      alt="$obs.label.rain" />
            #if $month.UV.has_data
            <img src="monthuv.png"        alt="$obs.label.UV" />
            #end if
            #if $month.radiation.has_data
            <img src="monthradiation.png" alt="$obs.label.radiation" />
            #end if
            #if $month.inTemp.has_data
            <img src="monthtempin.png"    alt="$obs.label.inTemp" />
            #end if
            #if $month.extraTemp1.has_data or $month.extraTemp2.has_data or $month.extraTemp3.has_data
            <img src="monthtemp.png"      alt="$obs.label.extraTemp1" />
            #end if
            #if $month.rxCheckPercent.has_data
            <img src="monthrx.png"        alt="$obs.label.rxCheckPercent"/>
            #end if
          </div>
          <div id="history_year" class="plot_container" style="display:none">
            <img src="yearbarometer.png" alt="$obs.label.barometer"/>
            <img src="yeartempdew.png"   alt="$obs.label.outTemp" />
            <img src="yeartempfeel.png"  alt="$obs.label.feel" />
            <img src="yearhum.png"       alt="$obs.label.outHumidity" />
            <img src="yearwind.png"      alt="$obs.label.windSpeed" />
            <img src="yearwinddir.png"   alt="$obs.label.windDir" />
            <img src="yearwindvec.png"   alt="$obs.label.windvec" />
            <img src="yearrain.png"      alt="$obs.label.rain" />
            #if $year.UV.has_data
            <img src="yearuv.png"        alt="$obs.label.UV" />
            #end if
            #if $year.radiation.has_data
            <img src="yearradiation.png" alt="$obs.label.radiation" />
            #end if
            #if $year.inTemp.has_data
            <img src="yeartempin.png"    alt="$obs.label.inTemp" />
            #end if
            #if $year.extraTemp1.has_data or $year.extraTemp2.has_data or $year.extraTemp3.has_data
            <img src="yeartemp.png"      alt="$obs.label.extraTemp1" />
            #end if
            #if $year.rxCheckPercent.has_data
            <img src="yearrx.png"        alt="$obs.label.rxCheckPercent"/>
            #end if
          </div>
        </div>
      </div>
    </div>

    <p class="footnote">
      This station is controlled by <a href="http://weewx.com/">WeeWX</a>, an
      experimental weather software system written in Python.
    </p>

    #include "analytics.inc"

</body>

</html>

John Kline

unread,
Apr 25, 2020, 11:18:07 PM4/25/20
to weewx...@googlegroups.com
That file now works. I tried it.

You did not comment out the week, month and year plots.

Would you happen to have week, month or year selected?  If so, you will see the plots since they are not commented.

I take it index.html is now updated, but you have not given us that key piece of information.

On Apr 25, 2020, at 8:12 PM, michael form <mike...@gmail.com> wrote:


To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/1b917b6e-5606-43c8-a9db-ef454eed8684%40googlegroups.com.

Michael Form

unread,
Apr 25, 2020, 11:39:29 PM4/25/20
to weewx...@googlegroups.com
John:

I commented out the week, month and year as well as the day and now the plots have finally disappeared on all. I assumed, perhaps incorrectly, that commenting them out on day would affect that display only.

Also, when doing "ls -l /var/www/html/weewx/index.html" now returns the correct date.
Previously, I had "ls -l /var/www/html/index.html" which gave me the static date that I noticed. My error.

So, I think that things are working as expected at this time so I am going to quit while I am ahead and go to sleep as it is getting rather late here in Massachusetts. Where are you located?

Once again, thank you for all of your help. Good night and stay well.

Michael
Reply all
Reply to author
Forward
0 new messages