How to Add Digg Button to Blogger Posts

How to Add Digg Button to Blogger Posts

Submitting a content from your blog to Digg.com brings more exposure and traffic to your blog. This post explains how to add a Digg button to your Blogger blog easily.

Please Note: Before Editing your Template, Save a copy of your current template by clicking ‘Download Full Template’ in ‘Edit HTML’ page of the Blogger ‘Layout’ Window and ‘Preview’ the changes before Saving.

  1. Go to Blogger Layout page – Edit HTML – and click Expand Widget Templates.
    How to Add Social Bookmark Links beneath Blog Posts in Blogger
  2. Now Search (Ctrl+F) for:
    </head>

    and REPLACE the above line with the following code:

    <!–DIGG BUTTON SCRIPT START–>
    <script type=’text/javascript’>
    (function() {
    var s = document.createElement(&#39;SCRIPT&#39;), s1 = document.getElementsByTagName(&#39;SCRIPT&#39;)[0];
    s.type = &#39;text/javascript&#39;;
    s.async = true;
    s.src = &#39;http://widgets.digg.com/buttons.js&#39;;
    s1.parentNode.insertBefore(s, s1);
    })();
    </script>
    <!–DIGG BUTTON SCRIPT END–>
    </head>
  3. Now again Search (Ctrl+F) for:
    <data:post.body/>

    and REPLACE the above line with the following code:

    <a class=’DiggThisButton DiggCompact’/>
    <div style=’clear: both;’/>
    <data:post.body/>

    (This is the code for Compact button. Refer below for more buttons)

    How to Add Digg Button to Blogger Posts
    (Medium)
    How to Add Digg Button to Blogger Posts
    (Compact)
    How to Add Digg Button to Blogger Posts
    (Icon)
    <a class=”DiggThisButton DiggMedium“></a>
    <a class=”DiggThisButton DiggCompact“></a>
    <a class=”DiggThisButton DiggIcon“></a>
  4. Now Save your template to see a digg button appearing below the post titles!

Hope it worked fine! Enjoy Digging!

You Might Also Like:






Article by Shafar.
Author: Owner and Admin of TipsBlogger.
To submit your guest posts here, please read the Guidelines and Benefits.
Get Updates via: Twitter | RSS Feed | Email

One Response to “How to Add Digg Button to Blogger Posts”

  1. ng says:

    thanks its really helpful for my blog

    http://whatwhyhow-cihu.blogspot.com/

Leave a Reply