clarkwinkelmann I was saying there's no link to /users, the only page added by FoF User Directory.

ooo gotcha, that is true. Since the Sitemap would list the /users pages all the SEO tracking software would yell at me saying those were all orphan pages since they had no incoming link 😆

IanM you can remove all users from the sitemap by adding this to your local extend.php:

I was hoping uninstalling the extension would then at some point update the sitemap to no longer have those pages....

  • IanM replied to this.

    MikeJones I was hoping uninstalling the extension would then at some point update the sitemap to no longer have those pages....

    fof/user-directory does not own the User objects, core does, so uninstalling it would not affect this unfortunately.

    a month later

    IanM

    If I make this change, will it cause some incompatibilities in future? For instance when I upgrade the forum when the next release is there, is there any danger in modifying PHP pages directly? And will this change be overridden, so that I will have to make it after each upgrade?

    • IanM replied to this.

      CyberGene by making the change in your local extend.php, you are safe from this being overwritten as Flarum does not change this file.

      18 days later

      How can I generate the sitemap.xml file? I've asked this question before. The automatic sitemap.xml file is not generated. The file is not created with the command.

        DursunCan what mode are you using?

        In "Runtime mode", it's normal for no file to be generated. Flarum answers the request dynamically through index.php

          DursunCan in runtime mode, the file doesn't exist on disk, but it can be reached through its URL: https://<your website>/sitemap.xml

          If you need to download it to pass it on to a search engine as file instead of URL for some reason, you can access that URL in your browser, then select "save page as..." to download it to your computer.

          In runtime mode, you shouldn't place any file at <flarum path on disk>/public/sitemap.xml, as the webserver would like switch to serving that file, and it will never be updated again.

          • AleM replied to this.
            2 months later

            Is the topic template up to date? Codes on the template etc. fof:sitemap:build @mekici

            6 days later

            FriendsOfFlarum datitisev clarkwinkelmann

            Hello, I'm using FoF Sitemap 1.0.3 set on Mutli file, on a Flarum 1.1.1 installation. I have over 100k discussions, with over 1M replies, but for some reason on Google Search Console I get only 27k valid pages, while other 27k are "Crawled - currently not indexed", 22k "Discovered - currently not indexed", 76k "Alternative page with proper canonical tag" and 77k "Page with redirect". What should I do to optimize this?

            12 days later

            IanM Simplify console commands into one new command fof:sitemap:build
            Add cleanup from other modes so that old sitemap files are not left behind
            Flarum 1.0

            Could someone change that in the initial description?

            I was wondering why my sitemap did get lost and google kept sending me mails. Thanks.

              11 days later

              Hari did this command got changed to php flarum fof:sitemap:build ?

              m4v3rick

              See my post 😉

              Guess so - documentation is not up to date.

                5 days later

                I found an error in flarum log;

                [2022-02-19 00:50:53] flarum.ERROR: Symfony\Component\Console\Exception\CommandNotFoundException: Command "fof:sitemap:cache" is not defined.

                Did you mean this?
                fof:sitemap:build in /var/www/html/vendor/symfony/console/Application.php:709
                Stack trace:
                #0 /var/www/html/vendor/symfony/console/Application.php(259): Symfony\Component\Console\Application->find()
                #1 /var/www/html/vendor/symfony/console/Application.php(171): Symfony\Component\Console\Application->doRun()
                #2 /var/www/html/vendor/flarum/core/src/Console/Server.php(42): Symfony\Component\Console\Application->run()
                #3 /var/www/html/flarum(24): Flarum\Console\Server->listen()
                #4 {main}

                anything wrong in my config?

                • Hari replied to this.

                  Hari I tried this from command line, sitemap.xml is created and being updated. I just wonder what these errors are?

                  Hari oh no, sitemap.xml does not update itself. I've to do it manually via runnig php flarum fof:sitemap:build command from cli.

                  I think related php files are not updated and still running old command fof:sitemap:cache

                  I am rewriting this extension from scratch (pretty much). So I don't think we'll patch this soon, unless someone else wants to do a patch release.

                  You can probably temporarily set up the correct command as a cronjob.