December 16, 2006
Social Bookmark Hacks

Sometimes, I really don't quite understand why I keep changing the structural elements of the blog.

Sometimes, I really don't quite understand why I keep writing new entries, but that's a different issue for another day.

Anyway, this idea of social bookmarking has me intrigued. So, I decided to add a couple of easy links for a couple of popular sites, digg and del.icio.us

It wasn't as hard as I had anticipated.  I created a new MT Template Module that contains the actual code to generate the links.  The key was to use the <$MTEntryPermalink$> and <$MTEntryTitle$> tags to construct the references.  I got put on the right track from an entry which gives specific examples for Movable Type on Dave Taylor's great site Ask Dave Taylor.

As an example, my code for digg is:

<!-- Start Digg -->
<img src="http://www.blogdom.org/images/digg.png" alt="Digg It!" /><a href="http://digg.com/submit?phase=2&url=<$MTEntryPermalink$>&title=<$MTEntryTitle$>" title="Digg It!" target="_blank">&nbsp; Digg It! &nbsp;</a>
<!-- end Digg-->

I then simply had to add calls to the new module in the entrybody module and the Individual Entry Archive module and then rebuild the site.

I'm still not super happy with the asthetics, but, it'll do for now.

I doubt I'll add any more, as I doubt I'll ever have an entry actually submitted to either, but, it was an interesting academic exercise.

Digg It!  Digg It!   del.icio.us bookmark  Bookmark it!  

Posted by David at December 16, 2006 08:33 PM
Comments
Post a comment

Ability to add comments removed due to spam.

If you wish to add a comment, send an email to comments at blogdom dot org

replacing the at above with @ and the dot above with .