How to Add a Digg Button to My Posts

Adding a Digg button to your blog posts allows visitors to bookmark your post on the Digg network and share it with other Digg users. You can add a Digg button to your blog posts by pasting a short snippet of design code into the blog post. To add the Digg button code, you’ll first need to access the HTML -- Hypertext Markup Language -- mode in your blog-hosting service’s post editor tool.

Instructions

    • 1

      Log in to your blog-hosting service. Click the “New Post” or “Create Post” option for the blog on which you want to include the Digg button.

    • 2

      Type a title for the blog post into the “Title” input field. Enter the main text of the blog post into the text input field. Format the text and add images to the post in the usual way.

    • 3

      Click “HTML” or “Code” in the toolbar above the blog post editor pane to change the input mode to HTML.

    • 4

      Click inside the post editor input box at your preferred insertion location for the Digg button.
      Paste the following code into the page:

      <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>

    • 5

      Type or paste one of the following lines of code immediately after the “</script>” tag in the code you’ve just pasted into the blog post editor:

      <!-- Wide Button -->
      <a class="DiggThisButton DiggWide"></a>

      <!-- Medium Button -->
      <a class="DiggThisButton DiggMedium"></a>

      <!-- Compact Button -->
      <a class="DiggThisButton DiggCompact"></a>

      <!-- Icon Button -->
      <a class="DiggThisButton DiggIcon"></a>

      Use only one of these four code lines. Use the code with the Digg button size that you want to include in the blog post.

    • 6

      Save and publish the blog post. Repeat this procedure each time you want to add a Digg button to your blog post.

Tips & Warnings

  • Add a Digg button to website pages by opening the HTML document in your usual Web design program or HTML editor and pasting the Digg code into your preferred location on the page.

Related Searches:

References

Resources

Comments

Related Ads

Featured