Disable search engine indexing on a particular category

January 25, 2009

How to disable search engine indexing on a particular category? First get the ID of the category you’d like to be not indexed by search engines. In this exemple, I assume your category id is 18. Open your header.php file and paste the following code between the <head> and </head> tags: <?php if ( is_category('18') || in_category('18') ) { echo '<meta name="robots" content="noindex">'; } That’s all. With the above code, we made sure that no post from category with the ID 18 as well as category... [Read the full story]

Disable search engine indexing on a single wordpress post

January 10, 2009

Most of the time, you want your posts to be indexed by search engines as such as Google as soon as possible. But if for some reason, you don’t want a particular post to be indexed by search engines. first get the ID of the post you’d like to be not indexed by search engines. In this exemple, We assume your post id is 18. Open your header.php file and paste the following code between the <head> and </head> tags: <?php if ($post->ID == 18) { echo '<meta name="robots" content="noindex">'; } That’s... [Read the full story]

Page 1 of 11