Proof of concept

Before we get WordPress involved at all, let's make sure that Digg's button works on a simple static page. If we can't make it work outside of WordPress, it's unlikely that we can make it work inside of WordPress. Take a look at the guide at http://about.digg.com/downloads/button/smart and get familiar with the sample code and the options available. We're going to try to make a simple static HTML page that implements a "Medium Smart Digg Button". According to Digg's documentation, all we need to do is add a bit of JavaScript to the document head and then use a special anchor tag on our page. Taking Digg's lead, the following is the HTML we've saved in a file named proof_of_concept.html:

<html> <head> <title>Proof of Concept</title> ...

Get WordPress 3 Plugin Development Essentials now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.