Have You ever wondered how you can add a link somewhere on your page, that will enable your users to submit your article to digg.com? It is rather easy to do it the simple way, by copying the digg link from digg.com, and putting it somewhere on your site for example as a hyperlink on some image. The digg url usually looks like this:
http://digg.com/programming/Microsoft_s_Unit_Testing_Framework_is_useles
Using it with image you get the following:
Digg This!
Most of the sites on the Internet currently provide you with the above. Is it perfect? I thought not, so I have searched for the better solution. What I wanted is to get the same digg link that is used on the digg.com. And after a while I have found few pages that explain how to do it. It's really easy. Just use the code below:
<div class="diggbutton"><script type="text/javascript">digg_url = 'http://digg.com/programming/Microsoft_s_Unit_Testing_Framework_is_useles';</script><script type="text/javascript" src="http://digg.com/api/diggthis.js"></script></div>
And what you get is:
Remember Me
a@href@title, strike
Powered by: newtelligence dasBlog 2.0.7226.0
Disclaimer The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.
© Copyright 2008, Michal Talaga
E-mail