You will see that many sites add a digg button within their post content. Some new users simply open single.php and add the digg script which will cause a digg button to show on all blog posts. But what if you want to display digg button on only specific posts? You can add it manually on each post when writing a post, but that is not the most efficient way. In this article we will show you, how you can add a digg button on specific posts by simply using Custom fields.
First open your single.php and find a code that looks like this:
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
Replace it with:
<?php if (have_posts()) : while (have_posts()) : the_post();
// check for digg button for single page
$digg = get_post_meta($post->ID, Digg, $single = true);
?>
Now you need to add the following code within the loop anywhere you like:
<?php // if there is a single page digg button
if($digg !== ) { ?>
<script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script>
<?php } // end if statement
// if there is not a digg button
else { echo ; } ?>
You may wrap it around with any styling that you want. Save the single.php and upload it to your theme folder.
Now when writing a post if you want to add a digg post simply add a custom field like shown in the screen shot below:

Whenever you specify this custom field, WordPress will display a digg button on your post like this one:
Check out this example (Live)
Original Source:http://www.wpbeginner.com/wp-tutorials/how-to-add-a-digg-button-in-your-wordpress-using-custom-fields/
Related Stuff
Google Buzz Button Wordpress Plugin ReleasedIf you are looking for a Google Buzz button to add into your Wordpress site then we have released the first Wordpress plugin exclusively ...
Plug And Play Ecommerce With Wordpress PluginsSince 2003 Wordpress has slowly been gaining popularity amongst the elite of the internet, the bloggers. It is one of those few things ...
Add Google Search to Your WordPress BlogThe native WordPress search does not return very relevant results, thus it makes a lot of sense to add Google Search into your WordPress ...
Add More Sidebars to Your WordPress ThemeYou can add more than one sidebar section to your WordPress site. For example, with the stc-intermountain.org site, I added a whole bunch ...
Series Posting in WordpressIn my functions.php file, I have some code which implements series posting. This relies on the thematic ...
