Home > Tutorial > Hide Certain Labels from Labels Gadget
Hide Certain Labels from Labels Gadget
Posted on Saturday, September 3, 2011 by android apps market for tablests
Two weeks ago I published one of my best Blogger tweaks yet, how to hide certain posts from Blogger homepage. You get to hide certain posts simply by labeling the post 'hide'. One of the ways to view the hidden posts is by clicking on the 'hide' label, or any other name that you've chosen to trigger the hide sequence. Blog reader 'Gardens Jewish Experience' wants this particular label to be taken off from the Labels gadget as well.
In this tutorial, you will learn how to remove a particular label from the Labels gadget. It is completely independent from last week's tutorial. Therefore, you can always use this tweak to hide certain labels from appearing on your Labels gadget.
Step 1:
It goes without saying that you have to have the Labels gadget already added before attempting this tweak. If you don't know how to add the Labels gadget, this tutorial probably isn't for you. Next, access your template's HTML.
In default layout: Go to Dashboard - Design - Edit HTML - Expand Widget Templates.
In new layout: Go to Dashboard - Template - Edit Template HTML - Expand Widget Templates.
Find and delete the following lines then.
The lines to be deleted (Ending portion):
It goes without saying that you have to have the Labels gadget already added before attempting this tweak. If you don't know how to add the Labels gadget, this tutorial probably isn't for you. Next, access your template's HTML.
In default layout: Go to Dashboard - Design - Edit HTML - Expand Widget Templates.
In new layout: Go to Dashboard - Template - Edit Template HTML - Expand Widget Templates.
Find and delete the following lines then.
<b:if cond='data:display == "list"'>The lines to be deleted (Starting portion):
<ul>
<b:loop values='data:labels' var='label'>
<li>
<b:if cond='data:blog.url == data:label.url'>
<span expr:dir='data:blog.languageDirection'><data:label.name/></span>
<b:else/>
<a expr:dir='data:blog.languageDirection' expr:href='data:label.url'><data:label.name/></a>
</b:if>
<b:if cond='data:showFreqNumbers'>
<span dir='ltr'>(<data:label.count/>)</span>
</b:if>
</li>
</b:loop>
</ul>
<b:else/>
<b:loop values='data:labels' var='label'>
<span expr:class='"label-size label-size-" + data:label.cssSize'>
<b:if cond='data:blog.url == data:label.url'>
<span expr:dir='data:blog.languageDirection'><data:label.name/></span>
<b:else/>
<a expr:dir='data:blog.languageDirection' expr:href='data:label.url'><data:label.name/></a>
</b:if>
<b:if cond='data:showFreqNumbers'>
<span class='label-count' dir='ltr'>(<data:label.count/>)</span>
</b:if>
</span>
</b:loop>
</b:if>
The lines to be deleted (Ending portion):
Step 2:
Paste the following lines in place of the deleted lines above:
New lines in place (Ending portion):
That is it. I've included two entry-hiding lines above. That means you can hide up to two labels with the code above. If you want to hide more entries, simply duplicate the lines I've highlighted above. Note: For each label, you need to add two conditional tags (example: Line 4 and 22). And make sure you close both of them (Line 16 and 34).
Paste the following lines in place of the deleted lines above:
<b:if cond='data:display == "list"'>New lines in place (Starting portion):
<ul>
<b:loop values='data:labels' var='label'>
<b:if cond='data:label.name != "hide"'>
<b:if cond='data:label.name != "ADDITIONALLABEL"'>
<li>
<b:if cond='data:blog.url == data:label.url'>
<span expr:dir='data:blog.languageDirection'><data:label.name/></span>
<b:else/>
<a expr:dir='data:blog.languageDirection' expr:href='data:label.url'><data:label.name/></a>
</b:if>
<b:if cond='data:showFreqNumbers'>
<span dir='ltr'>(<data:label.count/>)</span>
</b:if>
</li>
</b:if>
</b:if>
</b:loop>
</ul>
<b:else/>
<b:loop values='data:labels' var='label'>
<b:if cond='data:label.name != "hide"'>
<b:if cond='data:label.name != "ADDITIONALLABEL"'>
<span expr:class='"label-size label-size-" + data:label.cssSize'>
<b:if cond='data:blog.url == data:label.url'>
<span expr:dir='data:blog.languageDirection'><data:label.name/></span>
<b:else/>
<a expr:dir='data:blog.languageDirection' expr:href='data:label.url'><data:label.name/></a>
</b:if>
<b:if cond='data:showFreqNumbers'>
<span class='label-count' dir='ltr'>(<data:label.count/>)</span>
</b:if>
</span>
</b:if>
</b:if>
</b:loop>
</b:if>
New lines in place (Ending portion):
That is it. I've included two entry-hiding lines above. That means you can hide up to two labels with the code above. If you want to hide more entries, simply duplicate the lines I've highlighted above. Note: For each label, you need to add two conditional tags (example: Line 4 and 22). And make sure you close both of them (Line 16 and 34).
Another thing. I've been extremely busy for the past few weeks, and I expect to be very busy for the next few weeks as well. I'll be moving to a new house, and I'm not gonna have access to the Internet for a few days. My only hope is to use tethering from my Android device to stay in touch with the cyberspace. After that I'll be attending the Google Top Contributors summit, so I'm not sure if I'll be able to respond to your questions in time. My apologies if it take ages for me to get back to your questions and comments. Cheers and God bless.
Category Article Tutorial
Powered by Blogger.
Blog Archive
-
▼
2011
(4034)
-
▼
September
(95)
- BlackBerry Curve 9360 review, price and specificat...
- Anna Hazare’s official Blog, Facebook and Twitter ...
- Flip Through Flickr Photos With Your Friends in Re...
- September Reflections
- Disable Certain Dynamic Views in Blogger
- Change Blogger's Dynamic View Background
- Obtaining Direct Links from Blogger Uploaded Images
- Windows 8 Logon Screen for Windows 7 and XP
- Google Toolbar for Firefox 5
- 160by2 Mobile Application
- Disable Social Networks From Tracking Your Cookies
- Delicious Makes a Great Comeback!
- Firefox 7 is Super-Fast: Will it Challenge Chrome?
- Install Windows 7 From USB Flash Drive Using Windo...
- Google+ Circles can be Shared Publicly
- New Friend’s activity tab for Facebook pages
- 100 SMS per day limit from today for Indian cellul...
- Windows 8 to Allow Login with Windows Live ID
- Library Loot: Fourth Trip in September
- Just Shy of Harmony
- The Lost Hero (MG)
- What's On My Nightstand (September)
- iPhone Voicemail Password
- Domain face book will not be free now
- [Windows] Edit and Modify PDF Files with Nitro Reader
- Buying a GadgetGet Alerts on Newer Models and Prices
- Aircel Full Free Gprs 2g 3g on PC via ULTRASURF an...
- Torn (MG)
- Iphone iOS 4.3.1 Untethered Jailbreak
- Google Drive. Google to unveil ‘Google Drive’ soon
- Cloud Computing Winner of Pass for ABC Cloud Compu...
- Reliance free 3g network trick via ucweb opera mod...
- Listen to Bollywood Songs Free with Chrome App
- How to merge your old and new Facebook lists
- Hack] How To Control Which Sites Appear on Chrome’...
- The Sunday Salon: Week In Review #38
- Open Blogger Picture Gadget Links in New Tabs
- Library Loot: Third Trip in September
- Downgrade iPhone
- iPad 3 Release Date
- How to Enable Facebook Timeline on your Account
- Bing Introduces Video Background: Is it a Publicit...
- 6 Recent changes in Facebook and purpose of launch...
- 2011 Challenges: Fall Into Reading
- Experience Windows 8′s Live Tiles feature with Mosaic
- How to download videos from Facebook
- Soon you can Tweet in Hindi and 4 other languages
- Give Access to Only Leave Comments on Google Docs
- Stabilize Shaky Camera Motion on YouTube Videos
- Your Facebook Password is Not Completely Case Sens...
- This Dark Endeavour (YA)
- Contest] Retweet and Win Pass for ABC Cloud Comput...
- How to change default landing tab on a Facebook page
- Get Full version of ‘Asphalt 6′ game free for iPhone
- Facebook introduces new ‘Smart’ Friends Lists
- Ommwriter Dana – The Simplest Writing App for Windows
- Backup and Restore Complete Browser Profiles of Ch...
- Google’s Most Powerful Advertisement for Google+
- How to Remove News Ticker on Facebook with Chrome
- DOWNLOAD TORRENT FREE FROM YOUR MOBILE PHONES
- Get symbian s60v3 / s60v5 certificate and keys wit...
- Download Full Windows 7 with service pack 1 (sp1) iso
- Mister Creecher (YA)
- Windows 8 Developer Preview
- iPhone 4 – 4.2 Jailbreak
- Mac Transformation Pack for Windows 7
- iPhone 5 vs iPhone 4
- Cool iPhone Apps
- iOS 4.3 Features
- How To Make A Facebook Fan Page
- Can iPhone 4 Be Unlocked?
- Blogger Vs WordPress
- How To Use iPhone As Modem
- Enlarging Blogger Slideshow Gadget
- Beneath the Night Tree
- The Autobiography of Mrs. Tom Thumb
- I, Claudius
- Blog Update
- The Sunday Salon: Week In Review #37
- Library Loot: Second Trip in September
- Home to Harmony
- A Pocket Full of Rye
- The Doctor's Lady
- Google Top Contributor Summit 2011 Day 1
- A Murder on the Links
- Wings of A Dream
- The Sunday Salon: Week in Review #35 and #36
- Library Loot: First Trip in September
- Human.4 (YA)
- The Five Red Herrings
- Wrapped (YA)
- Hide Certain Labels from Labels Gadget
- My Life Undecided (YA)
- R.I.P. VI
- Katherine
-
▼
September
(95)




