Download
We're evolving to serve you better! This current forum has transitioned to read-only mode. For new discussions, support, and engagement, we've moved to GitHub Discussions.

Last modified date/time missing from sitemap

  • #3196
    Avatar photo[anonymous]
    #3199
    Avatar photo[anonymous]

    Which theme are you using?

    #3200
    Avatar photo[anonymous]

    Simple. With template overrides.

    I’ve found what’s doing it.

    If you use pretty urls in site settings then you have to have a tag prefix, which creates an extra empty directory between the route and the page page in the url, eg topics.

    I didn’t want to do that so I edited the site config json, so that tagsPrefix was empty again. see below.

    This seemed to work fine – all the pages etc generate. The one thing that doesn’t – it seems – is that the last modified timestamps disappear from the sitemap. if add the text back into the config it works again.

    “urls”:{
    “cleanUrls”:true,
    “addIndex”:false,
    “tagsPrefix”:””,
    #3201
    Avatar photo[anonymous]

    Hi,

    Okay, got it.

    If you choose “Use Pretty URLs” from Site Settings > URLs, then you must (normally) enter some text for “Tags prefix:”.

    But then, looks like you edited line 77 of config/site.config.json, to delete the entry.

    Even with attempted site override of site.config.json, that probably won’t work.

    So it’s probably not really a bug because it’s meant to have a “Tags prefix” text entry when you opt for “User Pretty URLs”  (that’s the option I often choose too).

    I’m doubt that you can override site.config.json. Perhaps double-check https://getpublii.com/dev/theme-overrides/#js-header

    Maybe @Bob can clarify.