Social Bookmarking Twiddling

Social Bookmarking Twiddling

: I was chatting with Brad over the weekend about making it easier for people to find our content, and he mentioned a plugin that would automatically add links to [], digg, and other social bookmarking services. The idea is that by making these bookmarking icons more accessible, people are more likely to bookmark interesting posts, which theoretically drives traffic.

Geeky notes follow!


I hunted down Cal Evan’s WordPress nifty plugin Notable and installed it. Couldn’t be easier! Every post now has 5 service icons; Notable actually supports a lot more, but I thought I’d start with the five ones that I had actually heard of first, and add more later if it didn’t start getting out-of-hand.

Because I can’t leave things alone, I did make some tweaks:

  • The graphic icons were of varying heights, which made them float unevenly in my layout. I made them all the same height (now 16 pixels, faded 50% to better work with my layout).

  • I added text to identify the service each icon represented. Rolling over the icons with the mouse does reveal which service the link goes to, but I am not a fan of rollover information. Help is one thing; information should be laid out where you can see it. Personal preference. Plus it looks kind of cool.

  • I fixed some typos in the function notable_define_array() that caused the output to fail XHTML validation.


p>This last case was the common “& where an &amp; should be” HREF encoding problem, but I couldn’t find it. I eventually figured out that that the digg, magnolia, and segnalo post_url values did not have their &s urlencoded properly, though all of the other ones were.

What made this typo particularly tricky to fix was that I thought I could just fix the definitions in notable_define_array(), not realizing that these values are copied once upon first-time installation of the Notable plugin. After that, they are pulled from the database and never updated even if you fix the typos. I was tearing my hair out trying to figure out if it was the browser cache, some mysterious PHP cache, or maybe a plugin post-processing my ampersands. Nope.

The workaround is to put the following code just before the blogbling_post_options (notable, $notable_settings) line at the end of the function:

    // ds: force update of post_url values
    $work = notable_define_array();
    foreach ($notable_settings['sites'] as $site=>$values_array) {
        $notable_settings['sites'][$site]['post_url'] = $work[$site]['post_url'];

After doing that, the XHTML validates again. Whew!

Another minor gotchya is the “image path”. I originally thought this was the full path to the plugin’s image directory, but it’s actually part of the URL that Notable uses to generate the <img> tags to display the icons. In other words, you’re filling out this:

not this:


Anyway, now that I have these little icons in place, I’m finding their colors too distracting, but maybe that will encourage people to click them. I’m a little doubtful that this will make a difference, but we’ll see.

UPDATE: I couldn’t stand it so I faded them out a bit.

The experiment in distributing original content continues!