Habari Plugin: Pull Quotes

UPDATE The plugin is now in the Habari Extras repository. There is a branch and tag for 0.6, and a 0.7 branch for the new plugin XML format. Any bugs/issues should be directed to the Extras Trac.

Unlike a blockquote, which is a HTML element meant to offset a quotation from the main text, a pull quote is a technique traditionally used in print to draw attention to a salient point in an article. Pull quotes generally take a small section of text and offset it from the article in a larger typeface. In addition to helping highlight a noteworthy point, a pull quote can add a graphic element by breaking up particularly long pieces of text.

Pull quotes were traditionally achieved in web publishing by appending the selected text to the end of the paragraph and then styling with CSS. The downside to that is that in mediums that don’t adhere to the style sheet (like syndication feeds), you wind up with the duplicate content at the end of a paragraph, which can confuse the reader to say the least.

Fortunately, through the wonders of jquery, Chris Coyier whipped up a way of simply wrapping the desired text in a span that clones the text and floats it. The beauty of this technique is that you’re not duplicating markup. Any medium that doesn’t recognize the class on the span simply ignores it, and the article reads normal.

With the help of Michael Harris who reworked the javascript, I’m proud to announce my first full fledged Habari plugin, simple as it may be. You can see it at work in this post and on another recent post.


Upload pullquotes to your user/plugins directory and activate the plugin. There is no configuration required. To create a pullquote from existing content, wrap the desired text in a span with a class of either pquote-r or pquote-l.


Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.


Pull Quotes has a default style included. To customize the CSS, make sure in your theme’s header file that $theme->header(); is called before the theme’s style sheet. You can then add span.pull-left and span.pull-right to your theme’s style sheet and customize the pull quote to fit your design and tastes.


Pull Quote version 0.2

Note: This plugin will eventually be handed over to the Habari extras repository, however in my exuberance of writing my first plugin, and desire to experience writing up a detailed post for one, I am releasing it on my personal site first. Once I test it against 0.5.2 to determine if a separate version is required, I will add it to the repo, so any bugs or feature requests should be logged in the extras trac. Comments certainly welcomed as well.

Gravatars 2.0 and Skippy’s Gravatars Plugin

I had heard that Gravatar 2.0 had been released, but hadn’t really paid much attention. Today, while doing a little housekeeping around the site, I noticed that none of my gravatars were showing up. After doing a little investigating, I realized it had to do with caching, among other things. First thing I did was dump the cache on my gravatars folder in wp-content. Second, I logged into the gravatar site, and re-associated my gravatar with my email that I use for that account. Still no gravatars, mine, or anyone else’s.

So I looked at the settings on Skippy’s gravatar plugin (which I like as I can set a local gravatar, vs using a default one from the original site), it was set to use caching. I turned that setting off, and voilá, gravatars are showing back up. Hopefully that could help someone else (though, from reading a few blogs, and the comments on the main site, there’s no guarantees the main site will be with fail).

Category Archives Plugin

(disclaimer)I’m not a coder, and this is my first attempt, I apologize if this isn’t properly documented or presented.

My very first WordPress Plugin! I’ve dabbled with a lot of areas of WP, but until this post in the support forums, I never really had an idea or need to write one. But after doing some reading, I found that there wasn’t a simple way to accomplish this task. All of WP’s archive features are based on date.

So with the help of alphaoide via #wordpress on IRC, I put together this simple plugin to accomplish the task. It worked fine on my test site, but may need some TLC before being good to go. Basically it outputs categories by name in an h2 tag, then lists post titles with a permalink to the post.

I tested this by creating a Page Template, then inserting the plugin code within the content div of the theme.
The code to insert is
< ?php mb_cat_archive(); ?>
(remove the space between the < and ?, I’m not sure why that is getting reformatted in the post)
I suppose this could be used in a sidebar, however it may create a very long list…
So to summarize, download the file, unzip, and upload to your wp-content/plugins directory.
Activate the plugin in the dashboard. Create the page template, inserting the above code, save, and upload to your themes directory.
Go to Write->Page, and choose the template you uploaded.
The new page should now list your categories with their appropriate posts.
I haven’t looked into how it handles posts with multiple categories, that will be on my todo list, I’m sure, if the plugin proves useful or popular. I’d also like to add some AJAX to hide the posts until you click on the category (that would make it much more sidebar friendly), and the ability to change the h2 tag to whatever one likes.

You can download the file via: