Sunday, May 3, 2009


How to Show Blogger Widget Only In Home Page Or Post Pages of blogger

How to Show Blogger Widget Only In Home Page Or Post Pages of blogger,as you have seen in wordpress blog its your wish to what widget and what add you want to show in sidebar of that page but this service cant be used in blogger as all sidebar bar widgets are linked to all pages in blogger including home page but now you can select the option which sidebar widget you want to show in blogger homepage and which one in all other blogger post pages.

As one more beautiful hack how to show only post titles in blogger home and label pages has also been released,dont forget to red about it.

Lets follow on this tutorial i.e how to show blogger widget only in home page or blogger posts pages.

Add the widget in blogger layout where you want to display in blogger.Now you wnt to select on which pages of blogger it should be displayed.

Now go to "Edit HTML" page.
Mark "Expand Widget Templates"

And Search for

<b:widget id='HTML3' locked='false' title='Your Title name you gave to your widget' type='HTML'>

The number in red can be any like 1,2,3,4 it depends on your no of widget your are adding but the title to the widget you gave will be same.

So to make the widget code find easily for you find the below word

<b:widget id='HTML

and you will find many codes like these so keep on matchng the title name of widget of them to which you want to show on different pages.

After finding the code of widget you want to display on different pages add the red codes to them as i have shown below.

To display the any Blogger widget only in HomePage


<b:widget id='HTML5' locked='false' title='Widget Title Name' type='HTML'>
<b:includable id='main'>
<b:if cond='data:blog.url == data:blog.homepageUrl'>
<!-- only display title if it's non-empty -->
<b:if cond='data:title != &quot;&quot;'>
<h2 class='title'><data:title/></h2>
</b:if>
<div class='widget-content'>
<data:content/>
</div>

<b:include name='quickedit'/>
</b:if>
</b:includable>
</b:widget>


Add the red codes as shown above in codes whch you found for that particular widget in your blog html.

To display widget in all posts pages but not in HomePage


<b:widget id='HTML3' locked='false' title='Widget Title Name' type='HTML'>
<b:includable id='main'>
<b:if cond='data:blog.pageType == "item"'>
<!-- only display title if it's non-empty -->
<b:if cond='data:title != &quot;&quot;'>
<h2 class='title'><data:title/></h2>
</b:if>
<div class='widget-content'>
<data:content/>
</div>

<b:include name='quickedit'/>
</b:if>
</b:includable>
</b:widget>


To Display Widget In Archive Pages


<b:widget id='HTML3' locked='false' title='Widget Title Name' type='HTML'>
<b:includable id='main'>
<b:if cond='data:blog.pageType == "archive"'>
<!-- only display title if it's non-empty -->
<b:if cond='data:title != &quot;&quot;'>
<h2 class='title'><data:title/></h2>
</b:if>
<div class='widget-content'>
<data:content/>
</div>

<b:include name='quickedit'/>
</b:if>
</b:includable>
</b:widget>

If you have any problem leave your comments.



Thanks for Alshuldudeja

Bookmark this post:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


........................................................................................................................................
If you liked the above post, then please subscribe to this blog :

Enter your email address:


2 comments:

Anshul on May 4, 2009 at 2:16 AM said...

Thanx for the backlink..i liked your blog template especially your bookmarking widget...its great 1

King ZAHA on May 4, 2009 at 9:52 AM said...

@ Anshul
You are welcome

Post a Comment

 

Advertise

Friends list

  • CA's easy-to-use security suite lacks sufficient protection to stop many of today's threats. Don't rely on it.A cursory look at CA Internet Security 2008 m...

Term of Use:

Disclaimer : The Contents Of this Site is Only for Knowledge Purpose, Do not use this in a wrong way.

Hacker's Alley Copyright © 2009 This template is Designed by Ipietoon. Sponsored by Hacker's Alley