Digg is a very popular social bookmarking website. A blog’s popularity is also measured by its presence in bookmarking websites. To enable users to digg easily, you can add a digg button on your blog’s posts in wordpress.
- Login to your wordpress blog (e.g. http://www.techwhiz.in/wp-admin/index.php) with administrator rights
- Goto ‘Editor’ from ‘Appearance’ menu in the left side-bar
- Click on ‘single.php’ from the list in right side-bar to open the file
- Locate the place where you wish to display the digg button (generally it is displayed after the title or after the tags in a post, i.e. search for ‘the_title’ or ‘the_tags’)
- Copy and paste the following codes at your selected location and save the file
Static Digg Button
This is a static button which enables user to bookmark particular post/page and is very easy to integrate with wordpress.
<a href=”http://digg.com/submit?url=<?php the_permalink();?>&title=<?php the_title();?>” target=”_blank”><img src="http://digg.com/img/badges/100×20-digg-button.png”/></a>
Smart Digg Button
This will also display the number of times the particular post/page has been bookmarked in digg.com.
|
|
| Normal | Compact |
- Normal Button
<a class="DiggThisButton" /><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script>
- Compact Button
<a class="DiggThisButton">(‘<img src="http://digg.com/img/diggThisCompact.png" height="18" width="80" alt="DiggThis" />’)</a>
<script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script>
For further details read this.









