April 19, 2011

How to Remove Blog Title from Page Title

By default, when you publish your post, the page title of the post becomes 'Blog Title : Post Tile". For example, the title of this post 'How to Remove Blog Title from Page Title' changes to 'Program Square: How to Remove Blog Title from Page Title'.

It seems not bad. But in situation where your posts are automatically linked to social network sites such as delicious.com, digg.com, and stumbleupon.com, it becomes little bit serious. All of my posts start with same words. Search engine as well as people think the posts are very similar or do not have good contents.

You can remove the blog title from the page title. It's too easy.

1. Sign-in your blogger account.

2. Go to Dashboard >> Design >> Edit HTML

3. Backup / Restore current template (use button in top of the showing page). Whenever you changes the HTML template, DO Backup before begin.

4. Using the find function of your browser(in most case, ctrl+F), find following expression. (You can just look up the codes to find it.)

<title><data:blog.pageTitle/></title>

5. Replace the line with following:
<b:if cond='data:blog.pageType == &quot;index&quot;'>
    <title><data:blog.pageTitle/></title>
<b:else/>
    <title><data:blog.pageName/></title>
</b:if>

Done.

Alternatively, following code changes order of page title and blog title. If you want to keep your blog title in page title, just replace upper code with following:

<b:if cond='data:blog.pageType == &quot;index&quot;'>
    <title><data:blog.pageTitle/></title>
<b:else/>
    <title><data:blog.pageName/>: <data:blog.title/></title>
</b:if>