如何防止搜索引擎索引我的网站的单个页面? [英] How to prevent search engines from indexing a single page of my website?
问题描述
我不希望搜索引擎索引我的印记页面。我需要一个简单的 robots.txt
>文件。基本上,这是一个文本文件,告诉搜索引擎不要索引特定的页面。
您不需要将其包含在页面的标题中;只要它位于网站的根目录中,它就会被抓取工具抓取。
在您网站的根目录下创建它,并将以下文本放入:
User-Agent:*
Disallow:/imprint-page.htm
请注意,您可以将示例中的 imprint-page.html
替换为页面的实际名称(或目录),你希望避免被索引。
就是这样!如果您想要获得更高级的功能,可以查看此处,此处或此处获取更多信息。此外,您可以在线找到免费工具,为您生成 robots.txt
文件(例如,这里)。
I don't want the search engines to index my imprint page. How could I do that?
You need a simple robots.txt
file. Basically, it's a text file that tells search engines not to index particular pages.
You don't need to include it in the header of your page; as long as it's in the root directory of your website it will be picked up by crawlers.
Create it in the root folder of your website and put the following text in:
User-Agent: *
Disallow: /imprint-page.htm
Note that you'd replace imprint-page.html
in the example with the actual name of the page (or the directory) that you wish to keep from being indexed.
That's it! If you want to get more advanced, you can check out here, here, or here for a lot more info. Also, you can find free tools online that will generate a robots.txt
file for you (for example, here).
这篇关于如何防止搜索引擎索引我的网站的单个页面?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!