Sunday, November 26, 2006

Allow your labels to be searched in Technorati and tags

Hello Friends,

I have developed a simple little add-on for your blog. To know what I am talking about, just see the labels in my post's footer. Notice the tiny Technorati pic beside each label. When clicked, it shows you all the posts from bloggosphere that have been tagged with the label in question. (See end of this post for how-to)

It is a good way to allow your reader to search Technorati using tags and serves as a sort of "related posts from other blogs" link. Installing this code is fairly simple. Just follow these steps:

1. Edit your template HTML code and check the "Expand Widget Templates" box. Make a backup of your template if you are not used editing HTML.

2. Look for your post footer i.e. look for <div class='post-footer'>

3. Then in there, look for the labels code i.e. look for <span class='post-labels'>

4. In there, look for the main label href i.e. look for:

<a expr:href='data:label.url' rel='tag'><></a>

and immediately after that line add this code:

<a expr:href='"" +' rel='tag' target='_blank' title='Search this tag on Technorati'/><img alt='' border='0' src='' style='vertical-align:middle'/></a>

That's it! It's as simple as that. However, let me know if your face any problems.

Update: How-to:

Deniz from has added the "search in tags" functionality to labels, on similar lines. You can access the code from here.

Technorati Tags: , ,


protesto said...

Nice hack Vivek. You can use this icon if you want. It fits better.

Vivek Sanghi said...


Appu said...

thanks man for such a great tip

Vivek Sanghi said...

You are welcome! thanks for stopping by!

Cyber-Buff said...

great hack buddy!!!!

protesto said...

Hi Vivek,

A little modification to your hack, searching for labels on the best known social bookmark manager

<a expr:href='"" +' rel='tag' target='_blank' title='Search this tag on'><img alt='d' border='0' src='' style='vertical-align:middle'/>

Vivek Sanghi said...

Thanks! :)


Gr8 idea! I am very happy with kind of varied use the label href code is being put to. First we have purpemoggy's label feeds, then my technorati search and now your search code.

I was wondering if all this can be combined and presented such that the label footers look neat and at the same time usability of these codes do not take a hit.

My idea is to have a drop-down such that by default the label name appears in the drop-down and when used the label feed, the technorati and links are available for use, but asthetically it may not look good and I want to avoid javascript coz it slows down my blog loading. You have any ideas?

protesto said...

You are right Vivek, asthetically it may not look good. Besides, there are many other bookmarking sites, so there is no limit for it. Actually I do not want to kick out my visitor from my blog by clicking other site's tags. So I think more than 3 tags are not so necessary.

Vivek Sanghi said...

Yeah agreed! Actually technorati, are enough and more needn't be added.

Singpolyma said...

If you wanted to have a whole list of things to search with each label you would probably use something similar to popmarks...

Vivek Sanghi said...

Hello Stephen. Popmarks like solution is perhaps the only way to keep the label footers neat. However, the original code will have to be redone for blogger beta. said...

i guess you didnt read my blog :)

Vivek Sanghi said...

Similar stuff and published much before me. Nice Work! However, I smell sarcasm in your comment :D So I wish to state that I don't plagiarize for my hacks and always acknowledge the source where I should. Thanks for stopping by cheers!

FoxyTallChick said...

Nice hack guys. I've just implemented it on my site: here. Like you said - it can get a little bit unwiedly if you have a lot of tags so I'm just going to see it goes for a while before deciding whether to keep with it. said...

sorry, never mean to be sarcasm. maybe because of my bad english...

i enjoy many of your posts and use some of them too.

Vivek Sanghi said...

@FoxyTallChick: Thanks for using my hacks. I hope we can improve it further. Cheers! Hey! No probs! Glad to know that you use my hacks. Let me know if you post some thing gr8! and I will tell my readers about your blog. Cheers!

GinVodka said...

hi vivek i had a problem, it showing word linke this :
Your template could not be parsed as it is not well-formed. Please make sure all XML elements are closed properly.
XML error message: The element type "b:loop" must be terminated by the matching end-tag "".

please give me a help

J said...

Ditto. I am receiving the same error messages.

troublemaker be said...

yes i'm too. i can't to do this hack. the error say about end tag-b:loop. please, what we must do?

Toinker said...

It's a good idea to put such code for your own blog. Thanks for posting this one dude.

LibAnn said...

Same issue on my end as well. I know this is an older post, but I would like to know if there is a way to resolve this issue.

Other posts @ Stubborn Fanatic

Click here to view all my posts.

< ? indian bloggers # >

« | # | RingSurf | ? | »

Top of Page

Creative Commons License
This work is licensed under a
Creative Commons Attribution-ShareAlike 2.5 License.

However, prior permission is required before you can display any content from this blog on your site. The author reserves the right to demand removal of such content at any time for any reason. (Not applicable for back-linking)
Note: The author is not responsible for any loss of data or damages to your homepage as a result of using the hacks suggested here. Please observe all necessary precautions while modifying template code.

© 2006 Vivek Sanghi a.k.a Stubborn-Fanatic