Warning: Undefined array key "HTTPS" in include() (line 29 of /opt/www/fdv2/drupal.stage/web/sites/default/settings.local.php).
include('/opt/www/fdv2/drupal.stage/web/sites/default/settings.local.php') (Line: 4)
require('/opt/www/fdv2/drupal.stage/web/sites/drupal001.net/settings.php') (Line: 145)
Drupal\Core\Site\Settings::initialize('/opt/www/fdv2/drupal.stage/web', 'sites/drupal001.net', Object) (Line: 1099)
Drupal\Core\DrupalKernel->initializeSettings(Object) (Line: 701)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
XMLSitemap的大小限制是多少?如何生成多个xmlsitemap提交给搜索引擎? - Drupal大学 - Drupal问答论坛
首页 / 帖子
XMLSitemap的大小限制是多少?如何生成多个xmlsitemap提交给搜索引擎?

XMLSiteMap不知道大小限制是多少,根据限制,生成多个sitemap如何提交给Google或者百度?

谢谢!

1个答案
AnnyO
发布于:2015-09-03 12:43

XMLSitemap的大小肯定有限制,具体的标准如下:

  1.  单个sitemap文件不能包括超过50000个URL;

  2. 单个sitemap文件大小不能超过10M;

  3. 单个管理员帐户向google提交的sitemaps不能超过500个;

  4. 一个sitemap中可以索引多个sitemaps;

  5. Sitemap 索引文件最多可列出 1,000 个 Sitemap;

因此,做一个sitemap.xml文件,索引出其他的sitemap文件即可。


索引的写法主要是sitemapindex标签和sitemap标签,具体如下:

<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <sitemap><loc>http://myweb.com/sitemap.xml?page=1</loc><lastmod>2015-09-03T02:10Z</lastmod></sitemap>
  <sitemap><loc>http://myweb.com/sitemap.xml?page=2</loc><lastmod>2015-09-03T02:10Z</lastmod></sitemap>
</sitemapindex>


Sitemap的标签主要是urlset和url,如下:


<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url><loc>http://myweb.com/63298</loc><lastmod>2014-11-19T03:16Z</lastmod><changefreq>yearly</changefreq></url>
</urlset>