WordPress Search Engine Optimization

If your blog displays archives, categories, tags and a search feature, you have to realize that the content in these sections is a duplicate of your original content shown in the ‘single’ page.
Therefore it would be very wise to list an excerpt only and not the full posts.

To do so, find this line:

<?php the_content() ?>

and replace it by

<?php the_excerpt() ?>

Now, you duplicate content is limited to the excerpts.
Still, a copy.
You may want to consider not having this content indexed. That’s what I do anyway.

Until now, I added the following lines to the header.php page:

<?php
if ((is_home() && ($paged < 2 )) || is_single() || is_page()) {
   echo ‘<meta name=”robots” content=”index,follow” />’;
}
else {
   echo ‘<meta name=”robots” content=”noindex,follow” />’;
}
?>

This few lines put a ‘noindex’ attribute in the robots meta tag of pages I don’t want to be indexed, but leaves the ‘follow’ in there, so the links are followed.

This code works like charm, but has one big disadvantage: you always have to update the header.php file whenever you install a new version.

Well, these days are over now.

I was browsing the blog of country fellowman Joost de Valk for WordPress SEO tips and found a great Meta Robots plugin.

Super easy to install and use and seems to do the job very well.

It’s not the first time I encourage you to check out Joost’s blog. Quite a few of my plugins are Dutch now!

Check it out and let me know what you think about it.




Share this post using these icons:
Facebooktwittergoogle_pluslinkedinmail

Related Posts

 

2 thoughts on “WordPress Search Engine Optimization

  1. Glad you like it Case! If you have any improvements for it, let me know!

  2. Case Stevens says:

    @Tanning Freak You’re better of using an excerpt on your archive and category pages. Thus all pages will be indexed and posts followed, while at the same time it’s not exactly duplicate content.

Comments are closed.