Get Latest Tricks Alert Daily
Follow Readers

How to Show or Hide Widgets in Blogger


SHARE:

Some questions that are most asked are : How to Show blogger widget on homepage only? How can I show widgets only on sub pages? How can I hide widgets on Static pages? How to show widgets on selected pages in blogger? To answer all these questions today's tutorial will be a delicious one. Its really important to control widget Display in Blogger. some widgets are meant for homepage only while some makes sense when you show it at your Contact Pages, About Me pages or static pages.
So how do we actually do this. The trick is really simple. You just need to enclose your widgets in few pieces of codes. So lets jump straight on how to manage widgets on different pages in blogger.

Its often the HTML/JavaScript widget that is widely used for adding your customized widgets to Blogger and its mostly this widget that needs to be easily managed. Since you often paste some widget code inside HTML/JavaScript widgets so the only extra thing that you need to do in order to control widget’s display is to enclose that code between two pieces of code as shown in each control codes below,

How to Show Widgets Only On Homepages?

Simply enclose the code inside HTML/JavaScript widget between these lines,
<b:if cond='data:blog.url == data:blog.homepageUrl'>
WIDGET CODE GOES HERE
</b:if>
where WIDGET CODE GOES HERE is the code of the widget you want to show or hide.

How to Hide Widgets On Homepages?

Same procedure here,
<b:if cond='data:blog.pageType == "item"'>
WIDGET CODE GOES HERE
</b:if>

How To Show Widgets Only On Static Pages?

<b:if cond='data:blog.pageType == "static_page"'>
WIDGET CODE GOES HERE
</b:if>

How To Hide Widgets On Static Pages?

<b:if cond='data:blog.pageType != "static_page"'>
WIDGET CODE GOES HERE
</b:if>

How To Show a Widget On a Selected Post Only?

<b:if cond='data:blog.url == "URL OF Selected Post"'>
WIDGET CODE GOES HERE
</b:if>

How To Hide a Widget On a Selected Post?

<b:if cond='data:blog.url != "URL OF Selected Post"'>
WIDGET CODE GOES HERE
</b:if>

How To Control Blogger’s Official Widgets?

The same procedure can be applied to Blogger’s official widgets like About Me, Archives, Poll etc. For controlling that widgets do this,
  1. Go To Blogger > Design > Edit HTML
  2. Backup your template
  3. Check the Expand Widgets Templates Box
  4. Search for the title of the widget you want to control
  5. The code for the widget will look something similar to this one,
<b:widget id='HTML' locked='false' title='WIDGET-TITLE-HERE' type='Profile'>
<b:includable id='main'>

LARGE CHUNK OF WIDGET CODE
</b:includable> </b:widget>
On finding the title in place of WIDGET-TITLE-HERE you will find two similar codes like those I have shown in bolded Red  You just need to add the Controlling codes in the following manner. For example if you wish to show a widget at Homepage only then do this,
<b:widget id='HTML' locked='false' title='WIDGET-TITLE-HERE' type='Profile'>
<b:includable id='main'>

<b:if cond='data:blog.url == data:blog.homepageUrl'>
LARGE CHUNK OF WIDGET CODE
</b:if>
</b:includable> </b:widget>

That’s it. Do the same for applying any controlling code. I hope this was useful :)




SHARE:



If you enjoyed this post and wish to be informed whenever a new post is published, then make sure you subscribe to our regular Email Updates!

Subscribe To Get Latest Tricks On Email!

 

7 comments:

  1. Alas! It is very sad to say but it can't be recovered at all. But you can send a guilty appeal to support@infolinks.com

    Regards,
    MyPremiumTricks

    ReplyDelete
  2. Inventions are growing very fast in this era. I read this post fully and got interesting information.
    Saudi Arabian Web Design Companies

    ReplyDelete
  3. very informative articular, Thanks for sharing this
    http://mybloggertools.com/

    ReplyDelete
  4. Thanks for sharing this
    http://helptrikslk.blogspot.com/

    ReplyDelete
  5. Get 1000+ Likes On Facebook Photos And Status
    Working 100% Visit:- www.Megsta.com
    -------------------------------------------------------
    Features:
    -------------------------------------------------------
    Facebook Auto Liker
    Facebook Auto Follow
    Facebook Auto Page Post Liker
    Facebook Auto Commenter Liker
    Facebook Auto Requests
    Facebook Auto Commenter
    Facebook Fan Page Liker
    No Skip Ad Problem
    No Spam,100% Working
    ------------------------------------------------------
    Visit:- www.Megsta.com

    ReplyDelete
  6. It’s really awesome. I love it.very interesting and meaningfull post. I got some very important views in your post which are very good and applicable for me. I just wish that I’ll see your another post very soon. I am waiting for that.
    hotmail password

    ReplyDelete