My website is setup where wordpress is installed in it's own subdirectory, but the content is served as though it's at the domain root.
(This wordpress codex page details the configuration)
Wordpress Url: https://www.example.com/wordpress
Site Url: https://www.example.com
So in this case, urls get re-written to NOT include /wordpress
in the url it serves pages from (although image urls do include it: https://www.example.com/wordpress/wp-content/uploads/...
).
URL for a page is: www.example.com/mypage/
NOT: www.example.com/wordpress/mypage/
but image link is: www.example.com/wordpress/wp-content/uploads/2018/12/25/image1.jpg
Question:
Do I put robots.txt
and sitemap.xml
in the "webiste root" directory on my server (example.com
)
or its wordpress
directory (example.com/wordpress
) ?
I cannot find this particular case in any searches.
Also trial and error is not helping, because I get conflicting results from various sitemap and robot validators.
Additionally, it seems some plugin or some part of WordPress insists on creating Virtual sitemap (sitemap.xml.gz
) and robot (robot.txt
) files, which further exasperates my efforts to definitively determine the proper location to place these files for this common, but non-standard of setup.