我通过以下链接http://www.sitemaps.org/protocol.html进行站点地图和交叉提交,但如果以下方法正确与否,则没有得到澄清:
我有以下网站,一个用于桌面用户,另一个用于移动用户,两者都提供不同的内容:
https://www.mainsite.com
并且https://mobile.site.com
两个域都指向同一个网站物理根目录,并且根据用户的设备,域 URL 已更改。
我在此根目录中放置了一个 robots.txt 文件,其中包含 sitemap_index.xml 文件的条目:
sitemap: https://www.mainsite.com/sitemap_index.xml
在 sitemap_index 文件中
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
<loc>
https://www.mainsite.com/sitemap_desktop_www.xml
</loc>
<lastmod>2015-09-04</lastmod>
</sitemap>
<sitemap>
<loc>
https://mobile.site.com/sitemap_mobile_www.xml
</loc>
<lastmod>2015-05-22</lastmod>
</sitemap>
</sitemapindex>
这种方法正确吗?
如果机器人读取域和 sitemap_index.xml 中的 robots.txt 和 sitemap_index.xml 文件,www.mainsite.com
它会忽略mobile.site.com
吗?