Wordpress: Add Technorati links to your tags
29 08 2008Ok, this one is fun. I wanted to find a way to list a posts tags at the end of the post, while at the same time providing links to that tag on Technorati. I went so far as to tweak the core Wordpress files before I was pointed in the right direction by WP guru Scott Spiel.
The code you’re about to see is on use over at BabyGotMac.com - click any article, then scroll down to see it in use.
To display a normal string of current tags, you would normally use “the_tags”. This gives you a flat list.
In order to accomplish what I wanted though, I used “get_the_tags”, as seen here:
I’ve posted this on PasteBin, and you can copy/paste it from here.
You’ll need a technorati.png file in your image folder obviously (steal mine from BGM if you want), and you will probably want to tweak the URL a bit, but this will get you a list of tags (linked to posts on your site tagged using that term), followed by a space and then the Technorati logo with a link to that tag on Technorati.
Hopefully someone will find this useful - let me know if you do, and please feel free to offer any modifications or thoughts.
Tags: babygotmac, code, technorati, wordpress
