Tuesday, September 11, 2007

Using Blogger Labels as Technorati Tags

Yesterday I work out a neat hack with Blogger labels. Only to find someone else had discovered it already. Anyway here it is.

  1. Open Blogger and navigate to Template > Edit HTML.
  2. Check the "Expand widget templates" box.
  3. Find the following code:

<br/>
<span class='post-labels'>
<b:if cond='data:post.labels'>
<data:postLabelsLabel/>
Read my posts about: <b:loop values='data:post.labels' var='label'>
<a expr:href='data:label.name' rel='tag'><data:label.name
/></a><b:if cond='data:label.isLast != "true"'>,</b:if>
</b:loop>
</b:if>
</span>.
4. And below it add this:


<br/>
<span class='post-labels'>
<b:if cond='data:post.labels'>
<data:postLabelsLabel/>
Technorati tags: <b:loop values='data:post.labels' var='label'>
<a expr:href='"http://technorati.com/tag/" + data:label.name' rel='tag'>
<data:label.name/></a><b:if cond='data:label.isLast != "true"'>,</b:if>
</b:loop>
</b:if>
</span>


5. If you want to show only the Technorati tags and not the labels, replace the first code with the second.

6. Note: The Tags will be whatever you put in as labels. In other words the labels and tags will be the same.

Technorati Tags all day long!


What next?

You can also bookmark this post using your favorite bookmarking service:

Digg this post
Add to Technorati Faves
Add to Google Bookmarks
Subscribe to the feed.

Search The Web Tools Blog: