Discuz! Board

 找回密碼
 立即註冊
搜索
熱搜: 活動 交友 discuz
查看: 5|回復: 0

Only applies to Google and Bing

[複製鏈接]

1

主題

1

帖子

5

積分

新手上路

Rank: 1

積分
5
發表於 2024-2-20 13:50:24 | 顯示全部樓層 |閱讀模式
User-agent: * Disallow: /blog/ Allow: /blog In this case, the URL /blog/post-title/ looks like it's forbidden, but it also looks like it's allowed. So which one takes priority? For Google and Bing, the rule is to prioritize directives with the most characters. This is the Disallow directive. Disallow: /blog/ (6 characters) Allow: /blog (5 characters) If Allow and Disallow directives are of equal length, the least restrictive directive takes precedence. In this case it would be the Allow directive. Note : Here it is accessible and crawlable /blog ( even without the trailing slash ).


Importantly, this only applies to Google and Bing . Other search engines follow the first matching directive. In this case, it will be Disallow. Sitemap  Australia Phone Number Data Use this directive to tell search engines where your sitemap is located. If you're not familiar with sitemaps, they typically contain pages that search engines crawl and index. Below is an example robots.txt file using the sitemap directive. Sitemap:User-agent: * Disallow: /blog/ Allow: /blog/post-title/ How important is it to include a sitemap in the robots.txt file? If you're already submitting through Search Console, it's a bit redundant for Google. However, it's still a good practice because it tells other search engines, such as Bing, where your sitemap is located.


        


Note that there is no need to repeat sitemap directives multiple times for each user agent. It doesn't just apply to one or the other. Therefore, we recommend that you include a sitemap directive at the beginning or end of your robots.txt file. for example: Sitemap:User-agent: Googlebot Disallow: /blog/ Allow: /blog/post-title/ User-agent: Bingbot Disallow: /services/ Google supports sitemap directives, as do Ask, Bing, and Yahoo .


回復

使用道具 舉報

您需要登錄後才可以回帖 登錄 | 立即註冊

本版積分規則

Archiver|手機版|自動贊助|zv

GMT+8, 2024-11-23 04:40 , Processed in 0.578024 second(s), 19 queries .

抗攻擊 by GameHost X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回復 返回頂部 返回列表
一粒米 | 中興米 | 論壇美工 | 設計 抗ddos | 天堂私服 | ddos | ddos | 防ddos | 防禦ddos | 防ddos主機 | 天堂美工 | 設計 防ddos主機 | 抗ddos主機 | 抗ddos | 抗ddos主機 | 抗攻擊論壇 | 天堂自動贊助 | 免費論壇 | 天堂私服 | 天堂123 | 台南清潔 | 天堂 | 天堂私服 | 免費論壇申請 | 抗ddos | 虛擬主機 | 實體主機 | vps | 網域註冊 | 抗攻擊遊戲主機 | ddos |