How to Add Digg Button to a Blog or Website

Adding Digg Button

Step 01: Log-in to your blogger account from here.
Step 02: Click on Template and then click on Edit HTML.
Step 03: Now you will be asked yo Proceed or Cancel. You have to click on Proceed.
Step 04: The HTML Editor will open. Now check the box where is written Expand Widget Templates.
Step 05: Now click anywhere of the codes and press Ctrl+F to enable search option.
Step 06: Type </head> or </body> to find out.
Step 07: Now paste the following codes given below before </head> or </body>.

<script type="text/javascript">
(function() {
var s = document.createElement('SCRIPT'), s1 = document.getElementsByTagName('SCRIPT')[0];
s.type = 'text/javascript';
s.async = true;
s.src = 'http://widgets.digg.com/buttons.js';
s1.parentNode.insertBefore(s, s1);
})();
</script>
Step 08: Again type <data:post.body/> in the search box and find out.
Step 09: Paste the following codes given below after <data:post.body/> tag.
<b:if cond='data:blog.pageType == "item"'>
<a class="DiggThisButton [Button Name]"></a>
</b:if>
Step 10: Now you have to replace [Button Name] with your preferred button name. There are three most common popular Digg Buttons. You can select one from these three. The name of the buttons are given below. Button 01: DiggWide Button 02: DiggMedium Button 03: DiggCompact

Related post



Recent Posts

The Most Popular Posts of This Blog