Save Space In Your Sidebar with Tabbed Widgets

I am engaged in an ongoing battle with my blog’s sidebar. I’ve never been sure what I’d like to put over there or how I want it laid out. When I recently switched to Tarski, I decided to revisit my widgets (hey, I made a funny) and see what I could do to make things easier.

Let me give you a little background. I like hacking code. Doesn’t matter what kind of code it is or even whose code it is. On the flip side of that, I don’t like re-inventing the wheel or making things harder than they have to be. I have no problem digging into my WordPress plugins and themes and fiddling with the PHP code in order to bend it to my will, but if there is an easier way, I’m all for it.

The Quest For a Tabbed Interface

Tabbed interfaces are pretty popular. They let you squeeze lots of info into a small space and help your interface to look cleaner and simpler. I was originally using the Javascript tabifier to achieve this type of widget in my sidebar, displaying my Recent Posts, Popular Posts, and Disqus comments.

It works well, but you have to do a lot of HTML editing withing your template, which makes it a pain to modify. That’s when I came across the Tabbed Widgets plugin. Once installed, creating a tabbed or accordion-style interface is simple. You simply select which WordPress widgets to include and the plugin creates a tab for each.

Disqus Doesn’t Have a WordPress Widget

I know, I was kinda shocked to. Let’s be clear, Disqus provides javascript code that you can paste on your blog to create a widget, but it does not provide an actual WordPress widget that you can drag to your sidebar. I figured they would have included this in the main plugin, but I can see why they may not have. They provide a variety of configurable Javascript widgets, so a WordPress plugin could be a pain.

This meant that I couldn’t really include Disqus in my tabbed widget because there was no widget to include (sorry, tried to make this sound simple, but it’s not working). That’s when I found the Disqus WordPress Widget plugin by Ivan Zlatev (Ivan on FriendFeed). See, I had already coded a very simple plugin on my own, but this one is much more useful. Once I got this installed, it was simple to create a Disqus tab and I can even configure the Disqus widget in my WordPress dashboard.

Easier is Always Usually Better

The only draw-back to this solution is that there must be an actual WordPress widget available to add to your tabbed interface. Trying to use a standard Text widget works, but if you have multiple Text widgets, there is no way to tell which is which. They will all be named “Text”. I found that it’s actually very simple to create a WordPress widget, so let me know if you’re having issues.

Now, I have a tabbed widget in my sidebar, completely configurable via my WordPress dashboard. I don’t need to know PHP or HTML to modify it or get it up and running. So, for those who are not technically inclined, this works out great. This means that I can focus my need to hack stuff on something else.

Suggestions? Have you tried Tabbed Widgets yet? Having trouble adding something? Maybe I can help…

Reblog this post [with Zemanta]