robots.txt的基本写法?
本文最后更新于 632 天前,文中的信息可能已经有所变化。如有误,请留言反馈。

robots.txt需要怎么设置?

详细解答:

robots.txt基本的写法:
1.禁止所有搜索引擎抓取网站任何内容:
User-agent:*
Disallow:/

2.允许所有搜索引擎蜘蛛抓取:
robots.txt设置为空文件或:
User-agent:*
Disallow:
或者:
User-agent:*
Allow:/

3.仅禁止某个搜索引擎抓取网站:
User-agent:(搜索引擎蜘蛛名称)
Disallow:/

4.仅允许某个搜索引擎抓取网站:
User-agent:(搜索引擎蜘蛛名称)
Disallow:
User-agent:*
Disallow:/

5.禁止蜘蛛访问某个目录:
User-agent:*
Disallow:/目录名称1/
Disallow:/目录名称2/
Disallow:/目录名称3/

 

[c-alert type=”warning”]此处应该注意,每个目录需要分开写,而不能写成:Disallow:/目录名称1//目录名称2//目录名称3/,User-agent:*后面的*代表的是any robot,所以不能写为Disallow:/abc/* 和Disallow:*.jpg这样的记录。[/c-alert]

 

搜索引擎蜘蛛,猫鼬博客

常见的搜索引擎蜘蛛名称:
1.百度蜘蛛:Baiduspider(抓取网页)、Baiduspider-image(抓取图片)、Baiduspider-video(抓取视频)、Baiduspider-news(抓取新闻)、Baiduspider-mobile(抓取wap)
2.谷歌蜘蛛:Googlebot
3.360蜘蛛:360Spider
4.SOSO蜘蛛:Sosospider
5.雅虎蜘蛛:Yahoo! Slurp China、Yahoo!
6.搜狗蜘蛛:Sogou News Spider、Sogou web spider、Sogou inst spider、Sogou spider2、Sogou blog、Sogou News Spider、Sogou Orion spider
7.MSN蜘蛛:msnbot、msnbot-media
8.Alexa蜘蛛:ia_archiver
9.有道蜘蛛:YoudaoBot、YodaoBot
9.必应蜘蛛:bingbot

暂无评论

发送评论 编辑评论


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
上一篇
下一篇