Narrated web site last change date on pages

Running Gramps 6.0.8 on Fedora 44.

Narrated web site pages have a line at the very bottom with a time and date of the last change, something like “Last change was the 2023-03-21 13:53:09”. First of all the word “the” does not belong. Also, this time and date is specific to the particular page being viewed. When seen on the home page one might thing it was the last update on the site as a whole.

I’d like to suggest a small (hopefully) change. Change it to read:

Last change on this page was <DATE> at <TIME>.

That just seems to make more sense.

Thanks for your consideration.

I was able to make this change myself. I edited the file:
/usr/lib/python3.14/site-packages/gramps/plugins/webreport/basepage.py.

I located the following lines:

       if date is not None and date > 0: 
            msg += "<br />" 
            last_modif = datetime.datetime.fromtimestamp(date).strftime( 
                "%Y-%m-%d %H:%M:%S"
            ) 
            msg += self.\_("Last change was the  %(date)s") % {"date": last_modif} 
        else: 
            dat_txt = self.\_(" on %(date)s") 
            msg += dat_txt % {"date": self.rlocale.get_date(Today())}

Then I modified the two lines read:

       if date is not None and date > 0: 
            msg += "<br />" 
            last_modif = datetime.datetime.fromtimestamp(date).strftime( 
                "%Y-%m-%d at %H:%M:%S"
            ) 
            msg += self.\_("Last change to this page was  %(date)s") % {"date": last_modif} 
        else: 
            dat_txt = self.\_(" on %(date)s") 
            msg += dat_txt % {"date": self.rlocale.get_date(Today())}

I did discover at one point I had to exit Gramps and restart it as apparently Gramps had a cache of the code prior to my changes.

I have a background in computer science and systems administrations but I am not a python programmer. However, this did seem like a pretty easy and simple change.

Oh, and for the curious, my web site is https://www.dennett.org.

Charlie

As the English language is constantly evolving and mutating I would
argue that grammatically the current expression is possibly inaccurate
but never the less acceptable.

Other Elements do need changing I feel.

So current
Last change was the 2023-08-09 13:53:09
Is this the month of August or September and how many viewers are really
going to be interested in the time of change to the second.
Suggestion
Page last changed on 9th August 2023
or
Page last changed on August 9th 2023
Depending on your preferred UK/US date format
Both appear acceptable to the various online grammar checkers
phil

This is not the date for the page but for the data related to this page.

We always set YYYY-MM-DD so it is august.

Serge

We always set YYYY-MM-DD so it is august.
I know that and other users of GRAMPS probably know that but if you pass
the Website on to A. N. Other which is the purpose of the Narrated Web
Site after all it is not necessarily obvious but is maybe an academic point.
phil