//

How To Place Title First In WordPress Title Tag Code

by Mr. Waltz on May 5, 2009



Wordpress logoTo start with,  your articles appearing in search engines are in this format: (Default Format)

Blog Name >> Blog Archive >> Title Post

i.e. Technama – Blog Archive – How to Place Title First In WordPress Title Tag Code

Now you want to change it to this format (Remember i am not necessarily saying that this is an SEO technique).

Title Post >> Blog Name>>Blog Description

i.e. How To Place Title First In WordPress Title Tag Code – Technama – TN is for Technology

So follow these and it will get you to your destination;

  • Log into the WordPress account.
  • Click on Presentation.
  • Now click the Theme Editor Link.
  • Now locate Header.php link (right side), and click it.
  • Now you are in the ‘Editing Header’ mode. Locate the following code;

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

This code presents your current format which is :

Blog Name>>Blog Archive>>Post Title (Article)

  • Now delete the above code and copy the code below:

<title><?php
if(is_home()) {
bloginfo('title');
echo
' - ';
bloginfo('description');
} else{
wp_title('');
echo
' | ';
bloginfo('title');
echo
' - ';
bloginfo('description');
}
?>
</title>

  • Replace the old code with the above code.
  • Click the Update file button and you are done here.

Now assuming you have followed the steps correctly, the format has change to this

Post Title>> Blog Name>>Blog Description

Hope you are satisfied with this tutorial. If you have any problems or queries and if you want a customized code, please feel free to tell us.

Related Articles:

  1. How to add Statpress Plugin (Daniele Lippi) in WordPress Blog
  2. How To Add Favicon In WordPress Coding
  3. WordPress Fatal error: Cannot redeclare wp_load_image() (previously declared in…
  4. Troubleshot: Warning: Cannot modify header information – headers already sent by (output started at… [WORDPRESS]
  5. WordPress Fatal error: Call to undefined function _deep_replace()…pluggable.php on line 884
  6. Download WordPress 2.8

{ 4 comments… read them below or add one }

Noris Walter May 5, 2009 at 12:54 pm

Yes! A simple yet very helpful tutorial. I had to face this problem myself and i solved it after spending a lot of time on google searching different sites. Ur post is very concise and helpful.

Reply

ArianaVorp May 13, 2009 at 5:54 pm

I think you love dark color

Reply

buy bedding May 20, 2009 at 5:56 am

Great, thanks!

Reply

Pamelarada May 23, 2009 at 6:39 pm

Great post, I hope one day to find my blog included in your list of top blogs you recommend.

Reply

Leave a Comment

Previous post:

Next post: