How To Get Digg Digg & Sexybookmarks To Work With Woothemes Bueno

I’m a huge fan of Woothemes themes, they can be uploaded & installed in seconds, have a nice framework & are able to be edited. I’m also a huge fan of Digg Digg & Sexybookmarks. Unfortunately, when testing with the free theme Bueno by Woothemes with a new blog – You’re Supposed To Be At Home, it lead to this problem with the featured posts section:-

What’s Happening Here?

As the featured section is treated as a separate post cycle, it’s includes whatever is included in the original post cycle, which includes the bookmarks. What we need to do is remove them.

Removing the Sexybookmarks from Featured Posts

To remove the Sexybookmarks from the Featured Posts, what you have to do is make sure that the featured posts feature the excerpt, rather than the content. Simply go to Appearance > Widgets, and change it to the following:-

Removing Digg Digg From The Featured Posts

To remove Digg Digg takes a little bit more work, and edit the actual theme. It’s a bit codey, but it’s straightforward!

1. Open theme-widgets.php file

Firstly you need to open the theme-widgets.php file (after backing it up, of course!). This file is located in the “includes” directory in the theme template (for this I’ll be talking about Bueno, the free Woothemes theme).

2. Edit the_excerpt Loop Using Regex

What we are doing here is editing the excerpt so instead of placing the excerpt on the page, we’ll remove the Digg Digg Links. Luckily the links are all wrapped in a div, so if we find the div using Regular Expression (Regex), we can remove it.

To do this you need to go line 207, which looks something like this:-

if($content == "excerpt") { get_the_excerpt(); }

Replace it with the following code:-

if($content == "excerpt") {
 $ex = get_the_excerpt();
 $ex = preg_replace("/<div class='[a-z_'<> =\/(){.A-Z,1-9[0\];:}?%-^\"!]*<\/div>/", "", $ex);
 echo $ex; }

This should get rid of any of the buttons from the featured posts. If it doesn’t please let me know & I will research further.

Still Stuck?

Contact me & I’ll help you sort this issue out.

Do I Still Like Woothemes?

Absolutely! I’m still a huge fan. The fact that you can dive into the code & edit it is a beautiful thing that many other templates don’t allow you to do easily. As such I’d recommend signing up for them. I’m subscribed to their monthly package, but you can download the themes one off as well. They’re well worth getting for your blog. Check them out!

WooThemes - Made by Designers