Friday, December 22, 2006

Adding digg to blogger

So I wanted to add the dig buttons you see around to my blog, not that anyone is going to even read mine but I though I would add it anyway. I found this post which pretty much says to make an html file with only this javascript and add it as an iframe. I looked at the source of the javascript and all it does is add and iframe so why would you add and iframe of an iframe? The other stupid thing is digg requires you to input the url of the digg story not the url of what you are digging. This makes it a pain in the ass and requires you to digg the story or the button wont even show up, you just get an error. The reddit button is makes much more sense and the url is the url of the story so you can easily add it to your blogger template like so.
<script>reddit_url='<$BlogItemPermalinkURL$>'</script> <script language="javascript" src=""></script>
The digg buttons I add to the blog post not the template like this:
<iframe src="[digurl]" frameborder="0" height="82" scrolling="no" width="55"></iframe>


Jeane Goforth said...

Thank you. After trying to implement the fixes posted elsewhere, yours was the first to make sense to me and to work. (I know just enough to be dangerous--and now I know a little bit more.)

Jeane Goforth said...

I went back to edit a link on one of my posts with a digg button. In the editing window, the post appears and then vanishes. I cannot click on the 'edit HTML' tab, either. This is true of each of the posts I added a digg button to, but not the others. Do you know why or how to fix this?

Jeane Goforth said...

Figured it out. It's a Firefox thing. I can edit the posts in IE.

WebbieGrrl Writer said...

Thanks so much, Justin. I can't believe Digg doesn't have a widget on the built-in share bar or even on the AddThis widget! Total bummer you have to add this to each and every individual post, but at least now--thanks to you--I can get users to Digg my posts. I'm trying to start a blog from scratch. Without Diggs, I have "no reach" at all!

Sarah, The Webbiegrrl Writer