Swap Blogger Title Hack – Error Free!


Blogger recently changed the way the layout codes are processed which prevented Blogger users to change their layout through the Page Elements Layout tab while using the Swap Title hack. Nobody could find a solution to this till now. Blogger introduced a new layout tag “blog.pageName” recently which gave me an idea to solve the Swap Title problem. I tested my method on this blog and guess what? It works just fine!

So without wasting any more time here is the all new “Error Free” Blogger Swap Title Hack:

  1. Backup your blog’s template just to be safe.
  2. Find this code in your template:
    <title><data:blog.title/></title> or <title><data:blog.pageTitle/></title>

  3. Replace the above tag with this:
    <!– Blogger Swap Title by Archit T at http://blog.archit.in –>
    <b:if cond=’data:blog.pageType == &quot;item&quot;’>
    <title>
    <data:blog.pageName/> | <data:blog.title/>
    </title>
    <b:else/>
    <title><data:blog.pageTitle/></title>
    </b:if>
    <!– End of Blogger Swap Title by Archit T at http://blog.archit.in –>

  4. Save your template and you’re done!

This hack does not return any XML errors which the older Swap Blogger Title Hacks do and it also lets you change your template layout through the Page Elements Layout tab! :)

Enjoy blogging and if you want more tips on blogging, you could subscribe to my blog feed.











34 Responses to “Swap Blogger Title Hack – Error Free!”

thanks Archit.finally i found the answer for my problem….

sachinKT added these pithy words on May 21 08 at 7:10 pm

Dude I’m excited about this – thanks for the code it works AND I can arrange page elements without breaking the XML – nice work. I have been searching for this code for Months.

subtle yet sheep added these pithy words on May 22 08 at 9:35 am

:)

Archit Tantia added these pithy words on May 22 08 at 10:55 am

Thank you so much! It worked perfectly on my blog .

M-Freeman added these pithy words on Jun 03 08 at 2:14 pm

Hi Friend,
After going through so many posts about this issue with buggy code, at last, I got the simple and perfect solution from your post… Thanks and keep the good work..
I modified my blog as per your instructions and is working fine.

Thanks again. ;-)

Emails 4 All added these pithy words on Jun 04 08 at 3:59 pm

It works!thanks…

Manpreet Singh added these pithy words on Jun 16 08 at 6:50 pm

thanks archit…
it was a nice tweak…

check out my tech blog at
http://technofreak.co.nr

Gautam added these pithy words on Jul 05 08 at 5:16 pm

hey archit i did exactly as u have said but my post title and blog title did not get swapped…pls help yaar….

boffin added these pithy words on Jul 24 08 at 10:47 am

@boffin You have 2 Title tags in your blog template. Remove the title tag which is on the 3rd line of your template and this hack would work just fine.

Let me know if you are not able to solve the problem.

Archit Tantia added these pithy words on Jul 24 08 at 11:21 am

Very useful hack.
Thank you!

MySpace Macedonia added these pithy words on Jul 29 08 at 12:46 pm

The only hack that worked for me, I’ve tried various title hacks for blogger by others but none worked..thanks!

Hilal added these pithy words on Jul 29 08 at 8:16 pm

No way not to say: THANK YOU!
I tried 2 other ways before I reach your post, but neither worked for me.
And, in my blog the tags that I had to replace were:
title data:blog.pageTitle/ /title – that might be because I’m using custom template.
I think you should include this in the post, so the newbies won’t give up on the first paragraph.

smokemachine added these pithy words on Jul 31 08 at 11:59 am

@smokemachine You are welcome smokemachine! Glad that this hack helped you.

Thanks for the correction though. I had already did the modification to the post but somehow forgot to publish it. Sorry for the inconvenience caused; the post has been updated.

Thank You!

Archit Tantia added these pithy words on Jul 31 08 at 1:47 pm

Hi, this does not seem to be working for me. My blog can be found at http://www.welcometogower.co.uk – any help really would be appreciated.
Cheers,
Chris

Anonymous added these pithy words on Aug 07 08 at 9:31 pm

@Anonymous The hack is working perfectly fine on your blog. While on the post pages, the title shows the post header first and then the blog title.

Archit Tantia added these pithy words on Aug 07 08 at 9:42 pm

Thanks Archit – I guess it was just me being stupid. Thanks for all your help.

Chris Elphick added these pithy words on Aug 08 08 at 12:45 am

Hello, nice work though from some reason very small number of my posts appear before the blog title, and only on google, and not yahoo. I implemented this hack two weeks ago. Advice? my blog is http://totalka.blogspot.com

Thanks
Ned

Ned added these pithy words on Aug 22 08 at 1:29 pm

@Ned The search engines take time to index your pages. Ping Google and Yahoo and they will slowly change their old indexes.

Archit Tantia added these pithy words on Aug 22 08 at 4:21 pm

I implemented in my site Cool it’s working.
Well I request Archit can know how to show post description under post title in search engine’s

MusicmuziK added these pithy words on Aug 30 08 at 7:29 pm

@MusicmuziK Hello MusicmuziK, you just need to add this META Tag to your blogger template: <meta content='YOUR DESCRIPTION HERE' name='description'/> under your blog's <head> template.

If you need to show different description for different posts of your blog, then use the hack I posted a few days ago:
http://blog.archit.in/2008/08/add-different-meta-tags-to-different.html

Cheers!

Archit Tantia added these pithy words on Aug 30 08 at 8:16 pm

Thanks I have implemented same at Free Indian stock tips> and now will be seeing whether I get the requisite advantage or not.

Analyst added these pithy words on Sep 23 08 at 12:59 pm

I tried many in the past but this is the only one that worked.Thanks a million.Cheers.

Great technology deals updated regularly
http://brillantdeals.in

groat added these pithy words on Nov 10 08 at 4:43 am

thanks.. I changed it for my blog http://podcast.hindyugm.com

it has really worked

शैलेश भारतवासी added these pithy words on Jan 07 09 at 7:49 pm

hey archit i did exactly as u have said but my post title and blog title did not get swapped…

I am not use two title tag

Bank added these pithy words on Apr 09 09 at 10:34 pm

@Bank: I checked you blog. It looks like you didn’t save the changes.

Please follow the instructions again and this time be sure to save it! :)

Cheers!

Archit Tantia added these pithy words on Apr 10 09 at 7:18 pm

Hi Archit, I tried the instruction that you gave here but it seems not working on my blog? Do I need to put something on the code that you’ve provided or not? When I did that and make a preview of it, the template change. I don’t know if there is something wrong. here is my blog http://onlinecabalbot.blogspot.com

nabster added these pithy words on May 02 09 at 7:34 pm

@nabster: Hey nabster, I checked your blog and looks like the hack is working just fine on your blog.

Archit Tantia added these pithy words on May 05 09 at 10:57 am

i haVE IMPLEMENTED.. NO ERRORS, BUT THE SWAPPING NOT DONE.. just showing the title of my blog alone there.. what to do?.. can u point any possible problems frnd.. i have done the same before some time.. and worked, now its not ..

pixelshots added these pithy words on Sep 02 09 at 10:14 am

@pixelshots I just checked your blog and seems the hack is working just fine.

The main page will just show the blog's title but the single blog post pages will show the post title first and then the blog's title.

Cheers!

Archit Tantia added these pithy words on Sep 02 09 at 12:37 pm

Hello Guru, what entice you to post an article. This article was extremely interesting, especially since I was searching for thoughts on this subject last Thursday.

rH3uYcBX

Anonymous added these pithy words on Dec 29 09 at 4:46 pm

I love this site! Thank you sooo much for all your posts!

Anonymous added these pithy words on Dec 31 09 at 1:37 am

Thank you so much for your siteI love everything about it.

Anonymous added these pithy words on Jan 02 10 at 1:47 am

Hello! I'm having some problems with my code and getting this hack to work, so I'm begging for any help you might be able to give. I'm sure your code is right, but I did something to my code that I can't for the life of me figure out. On the main address for my blog there is now no title and on the post pages the name of my blog is the only title. I'd be grateful for any advice you can give. Thank you!

Diana Lee added these pithy words on Jul 29 10 at 8:03 am

Thank you! This is exactly what I needed.

Diana Lee added these pithy words on Aug 12 10 at 4:02 am

Leave a Reply