Hi folks, I am going to get straight to the point. I am sure a lot of you had a same issue with WP titles on your blog like I did. Simply put - I didn’t like them and they were not especially SE optimized. After a long research I assembled my Ultimate SEO Wordpress Titles code that you can use on your blog.

Let me tell you what it does.

  1. On Home Page - You will get a title like this:
    Blog Name » Blog Description
  2. On Single Pages - You will get a title like this:
    Post Title » Blog Name
  3. On 404 Error Pages - You will get a title like this:
    404 Error! Page Not Found » Blog Name
  4. On Search Pages - You will get a title like this:
    Search Results for: <KEYWORD> » Blog Name
  5. On All Other Pages - You will get a default title

In my (not so humble) opinion, this is a best way to deploy titles on your wordpress blog, both for humans and SE. If you feel like using these, at least give me some link love on your blog or simply subscribe to my feed on the right. Thanks.

Here is the code:

<title>
<?php if(is_home()) { ?>
<?php wp_title(’&raquo;’,'true’,'right’); ?><?php bloginfo(’name’); ?> &raquo; <?php bloginfo(’description’); ?>
<?php } else if(is_single()) { ?>
<?php wp_title(’&raquo;’,'true’,'right’); ?><?php bloginfo(’name’); ?>
<?php } else if(is_404()) { ?>
404 Error! Page Not Found &raquo; <?php bloginfo(’name’); ?>
<?php } else if(is_search()) { ?>
Search Results for: <?php echo wp_specialchars($s, 1); ?> &raquo; <?php bloginfo(’name’); ?>
<?php } else { ?>
<?php wp_title(’&raquo;’,'true’,'right’); ?><?php bloginfo(’name’); ?> &raquo; <?php bloginfo(’description’); ?>
<?php }?>
</title>

Popularity: 15%