admin管理员组文章数量:1122832
I uploaded my sitemap.xml to my Index of folder.
I tried to open sitemap.xml by example/sitemap.xml
but it won't work.
If I try with example/wp-admin/sitemap.xml
it will open my sitemap.xml.
I want to open my sitemap.xml by using this link example/sitemap.xml
only but where can I find the root folder? Where do I need to place my sitemap.html file?
I uploaded my sitemap.xml to my Index of folder.
I tried to open sitemap.xml by example.com/sitemap.xml
but it won't work.
If I try with example.com/wp-admin/sitemap.xml
it will open my sitemap.xml.
I want to open my sitemap.xml by using this link example.com/sitemap.xml
only but where can I find the root folder? Where do I need to place my sitemap.html file?
3 Answers
Reset to default 2The root of your site is where the wp-admin, wp-content and wp-includes folder is. From what you are showing in the image this does not appear to be the actual root directory of your Wordpress installation.
You could make this easier with the plugin mentioned by the other answer but if you are looking for something more custom then you'll need to find the actual root.
Difference between Site Root and WordPress Root
It's important to differentiate between both variants. The Root of your Domain/Website depends on the settings of your webhost. Some might give you ftp access to directories above the web root, and some might put you directly in the web root when accessing your ftp data. When you upload a file for testing, and it is available on yourdomain.com/yourfile.txt
, that directory is the webroot. You can put your WordPress installation in this directory or any directory below. For Example your whole WordPress installation can be in yourdomain.com/sub/directory/blog
, if this makes any sense to you.
In this case your Web root would still be yourdomain.com
, while your WordPress root would be yourdomain.com/sub/directory/blog
.
Inside your WordPress Directory you will have additional folders like wp-admin
, wp-includes
, wp-content
. It looks like you uploaded your file into wp-admin
.
Sitemaps
When you say you upload your sitemap I assume you have generated that locally. Just let me note that it is totally possible, and good, to let a WordPress plugin do this job, assuming you are using only WordPress for your content. There are several Plugins out there doing this job (one example would be XML Sitemap & Google News). This would probably make things easier.
So you could upload your file into another directory (once you find out where your webroot is) or use a WordPress plugin to generate the sitemap for you.
Where I can find the root folder?, Where I need to place my sitemap.xml file?
The root folder is the folder that is the top most directory of your project. Root directory contains your wp-config.php file. The sitemap.xml needs to be in root directory only.
If you are using Wordress then you don't need to create your sitemap. There is a plugin called Google XML Sitemap which will do your work.
This plugin creates the sitemap in your root directory i.e www.example.com/sitemap.xml
so that the search engine will index your site better.
So whenever you have created a post or page, the sitemap will automatically get updated with the latest content.
If you have further query please go through their FAQ.
本文标签: Where do upload sitemapxml in WordPress
版权声明:本文标题:Where do upload sitemap.xml in WordPress? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736310335a1934340.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论