{"id":357,"date":"2021-08-13T22:24:30","date_gmt":"2021-08-13T14:24:30","guid":{"rendered":"https:\/\/blog.cauchyschwarz.com\/?p=357"},"modified":"2021-08-13T22:25:17","modified_gmt":"2021-08-13T14:25:17","slug":"robots-txt-file","status":"publish","type":"post","link":"https:\/\/blog.cauchyschwarz.com\/?p=357","title":{"rendered":"Robots Txt File"},"content":{"rendered":"\n<h1 class=\"wp-block-heading\"><a href=\"https:\/\/developers.google.com\/search\/reference\/robots_txt\">robots.txt\u6587\u4ef6\u89c4\u8303<\/a><\/h1>\n\n\n\n<ul class=\"wp-block-list\"><li>robots.txt\u6587\u4ef6\u5fc5\u987b\u4f4d\u4e8e\u4e3b\u673a\u7684\u9876\u7ea7\u76ee\u5f55\uff0c\u6293\u53d6\u5de5\u5177\u4e0d\u4f1a\u68c0\u67e5\u5b50\u76ee\u5f55\u4e2d\u662f\u5426\u5305\u542brobots.txt\u6587\u4ef6<\/li><li>robots.txt\u53ea\u5bf9\u8be5\u4e3b\u673a\u3001\u57df\u540d\u3001\u534f\u8bae\u548c\u7aef\u53e3\u53f7\u4e0a\u7684\u6240\u6709\u5b50\u76ee\u5f55\u4e2d\u7684\u6587\u4ef6\u751f\u6548<\/li><li>\u5b50\u7f51\u57df\u4e0a\u7684robots.txt\u4ec5\u5bf9\u8be5\u5b50\u7f51\u57df\u6709\u6548<\/li><li>ftp\u4e5f\u53ef\u4ee5\u8bbe\u7f6erobots.txt<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">\u6b63\u5f0f\u8bed\u6cd5\u5b9a\u4e49<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>  robotstxt = *(group \/ emptyline)\n  group = startgroupline                    ; We start with a user-agent\n          *(startgroupline \/ emptyline)     ; ... and possibly more user-agents\n          *(rule \/ emptyline)               ; followed by rules relevant for UAs\n\n  startgroupline = *WS \"user-agent\" *WS \":\" *WS product-token EOL\n\n  rule = *WS (\"allow\" \/ \"disallow\") *WS \":\" *WS (path-pattern \/ empty-pattern) EOL\n\n  ; parser implementors: add additional lines you need (for example, Sitemaps), and\n  ; be lenient when reading lines that don\u2019t conform. Apply Postel\u2019s law.\n\n  product-token = identifier \/ \"*\"\n  path-pattern = \"\/\" *(UTF8-char-noctl)    ; valid URI path pattern; see 3.2.2\n  empty-pattern = *WS\n\n  identifier = 1*(%x2d \/ %x41-5a \/ %x5f \/ %x61-7a)\n  comment = \"#\" *(UTF8-char-noctl \/ WS \/ \"#\")\n  emptyline = EOL\n  EOL = *WS &#91;comment] NL         ; end-of-line may have optional trailing comment\n  NL = %x0D \/ %x0A \/ %x0D.0A\n  WS = %x20 \/ %x09\n\n  ; UTF8 derived from RFC3629, but excluding control characters\n  UTF8-char-noctl = UTF8-1-noctl \/ UTF8-2 \/ UTF8-3 \/ UTF8-4\n  UTF8-1-noctl    = %x21 \/ %x22 \/ %x24-7F  ; excluding control, space, '#'\n  UTF8-2          = %xC2-DF UTF8-tail\n  UTF8-3          = %xE0 %xA0-BF UTF8-tail \/ %xE1-EC 2( UTF8-tail ) \/\n                    %xED %x80-9F UTF8-tail \/ %xEE-EF 2( UTF8-tail )\n  UTF8-4          = %xF0 %x90-BF 2( UTF8-tail ) \/ %xF1-F3 3( UTF8-tail ) \/\n                    %xF4 %x80-8F 2( UTF8-tail )\n  UTF8-tail       = %x80-BF<\/code><\/pre>\n\n\n\n<ul class=\"wp-block-list\"><li>\u884c\u548c\u89c4\u5219\u5206\u7ec4<\/li><li>\u7528\u6237\u4ee3\u7406\u7684\u4f18\u5148\u987a\u5e8f<\/li><li>\u7ec4\u6210\u5458\u89c4\u5219<\/li><li>\u57fa\u4e8e\u8def\u5f84\u503c\u7684\u7f51\u5740\u5339\u914d<\/li><li>Google\u652f\u6301\u7684\u975e\u7ec4\u6210\u5458\u884c<br>\u53ef\u4ee5\u5728robots.txt\u6587\u4ef6\u4e2d\u6dfb\u52a0\u4e00\u884c<code>sitemap: [absoluteURL]<\/code>\u6307\u5b9asitemap\u3002<\/li><li>\u7ec4\u6210\u5458\u884c\u7684\u4f18\u5148\u987a\u5e8f<\/li><\/ul>\n\n\n\n<p>\u8fd9\u4e9b\u89c4\u5219\u6284\u4e00\u904d\u4e5f\u6ca1\u5565\u610f\u4e49\uff0c\u6309\u9700\u53bbgoogle\u7684\u5b98\u7f51\u9875\u9762\u67e5\u9605\u5c31\u597d\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>robots.txt\u6587\u4ef6\u89c4\u8303 robots.txt\u6587\u4ef6\u5fc5\u987b\u4f4d\u4e8e\u4e3b\u673a\u7684\u9876\u7ea7\u76ee\u5f55\uff0c\u6293\u53d6\u5de5\u5177\u4e0d\u4f1a\u68c0\u67e5\u5b50\u76ee\u5f55\u4e2d\u662f\u5426\u5305\u542brobots.txt\u6587\u4ef6 robots.txt\u53ea\u5bf9\u8be5\u4e3b\u673a\u3001\u57df\u540d\u3001\u534f\u8bae\u548c\u7aef\u53e3\u53f7\u4e0a\u7684\u6240\u6709\u5b50\u76ee\u5f55&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[10],"tags":[28],"class_list":["post-357","post","type-post","status-publish","format-standard","hentry","category-10","tag-28"],"_links":{"self":[{"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=\/wp\/v2\/posts\/357","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=357"}],"version-history":[{"count":2,"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=\/wp\/v2\/posts\/357\/revisions"}],"predecessor-version":[{"id":359,"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=\/wp\/v2\/posts\/357\/revisions\/359"}],"wp:attachment":[{"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=357"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=357"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.cauchyschwarz.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=357"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}