Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
1.3k views
in Plugins by
edited by
Seems the xml sitemap does not list custom pages ? How to add them ?

A custom sitemap seems as well not to work ?
Q2A version: 1.5.1

1 Answer

+1 vote
by
selected by
 
Best answer

Two ways, both plugin "hack", file qa-xml-sitemap.php

  • You can ask your database and add links to sitemap by script if you know php good;
  • you can add links manualy in this file. Code below

qa-xml-sitemap.php

after line 159

echo '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">'."\n";

add:

echo "\t<url>\n".
"\t\t<priority>0.25</priority>\n".
"\t</url>\n";
 
On my site it working:
 
 
I will work more on it, I need automatic generation too, but for now it is ok for me.
by
or better add code after this:
        function sitemap_output($request, $priority)
        {

this very end of this file
by
Great, thank You, I can add these links manually as I have only limited php knowledge. I am sure with 1.6 the feature will be added to sitemap plugin anyway.
by
could you provide the php code to add pages automaticly?
...