WordPress header.php meta description and title

Sunday, 31 August 2008, 102

I am researching the best meta tags and title for seo on wordpress. I used only following my “M Theme”‘s header.php.

<title>
<?php bloginfo('name'); ?>
<?php if(is_single()){?> &raquo; Blog Archive
<?php } wp_title(); ?>
</title>

But I saw some different hints at google webmasters / tools. So I found some codes. Now I test following code  in “E theme”‘s header.php

<meta name="description" content="<?php if (!is_home())
{single_post_title('',true);}
else{ bloginfo('name');echo" - "; bloginfo('description');}?>" />
<meta name="keywords" content="" />
<title>
<?php bloginfo('name'); ?>
<?php wp_title(); ?>
</title>

And I also research the faster code.


Comments

  1. Is the fastest code <title><?php bloginfo('name'); wp_title() ?></title>?

    Posted by M | 02 September 2008 00:36
  2. Great site, I will be back. Well done

    Posted by Power Home Solar Review | 27 January 2010 07:21
Leave a comment
Name(required)
Mail (will not be publishing) (required)
Website

  • "I am a dreamer. Seriously, I'm living on another planet."
  • Lütfü Hoca

  • Categories

  • Archives