jQuery BBQ: Better Blockquotes

jQuery BBQ: A blockquote (AKA pullquote) script, that will unobtrusively grab content from your webpage and display it similarly to the way newspapers do it (see Wikipedia’s definition of a pull quote).

It can either be dropped directly into the webpage, with no configuration, or can take a number of customization parameters if you want to get creative with it. It is very lightweight – only 2.2 Kb (to which you will need to add the size of your jQuery distro).

Continue reading

Polyglot search fix

While implementing the Polyglot plugin on a WordPress site I was working on, I found a bug related to the search form: the plugin appends “/lang-pref/en/” (or whatever other ISO language code) to the search string (in the URL – when using “pretty permalinks” AKA URL rewriting).

This does not directly affect the first search, but the search field is then filled with “my search string/lang-pref/en”, which is confusing for the visitor.

A quick solution is to filter the search query and remove the said string Continue reading

Quick & dirty fix for Slimbox to attach itself to all images

While implementing yet another a WordPress site, I found myself in the situation where I wanted to display any and all images in lightboxes, but with a minimum of interaction from the editor’s part.

All current plugins that integrate Slimbox (that I know of – this one, for example) actually require the editor to add the rel="lightbox" attribute. But since the editors of this site have no HTML knowledge whatsoever and will be editing in “visual” mode, this hinders deployment.

So I came up with a modification to the actual javascript of Slimbox, to make it identify all links to images and lightboxify them :) Continue reading

One year’s statistics – thanks :)

This website is just over a year, the MOOdalBox page just went over 100.000 views and I just cashed in my first AdSense payment – a fabulous $100.78 :D (gathered in about a year)

It’s not much, but it pays for the hosting plan of this website – which means that this site is self-sustained.

I’ve grown to about 12.000 visitors with around 30.000 page views a month.

And this, for a blog with less than 30 posts. This is a wake up call for me: I will put more time in this site, from the little I have left, after my day job and my freelance projects.

I have so many ideas, like, for instance, the long awaited MOOdalBox 2 (lots of people have asked me when it would come out, I’ve made and broken so many promises on this subject :().

To sum it up, I feel the need to thank all my visitors for spending a moment here and for supporting me on every occasion. Thanks guys :)

SkinShare tutorial for an age verification using MOOdalBox

MOOdalBox has the the honor to be the first featured post on the SkinShare dev blog, with a tutorial on how to make a quick and easy age verification procedure.

SkinShare age verification

Unfortunately, this is a JavaScript only method – so it’s easily bypassed. I’ll have a version that uses more server-side scripting ready some time soon (for a project I’m working on), but this is cool and can easily enough be used just as a warning.

Site / playground / forum downtime :(

As some of you may have noticed (and thanks to those that notified me of the errors), the site was down for two days, the forum had errors, the playground was 404 :(

This was due to a server change I requested because of frequent downtimes on the previous one. However, the new server my site was moved to had certain features differently configured – that rendered my site inaccessible.

First was the php version, that made my WordPress installation go AWOL (had to switch from php 5 to 4 to have it work). That also lead to errors on my forum pages, but those were corrected using some tips from the bbPress forums.

The cause of 404′s on my playground folders was that my .htaccess for that folder used the directive SecFilterEngine Off, in order to disable mod_security (which, when activated, interfered with my Ajax calls). But on this particular folder, mod_security wasn’t configured and thus the .htaccess generated an error and wasn’t correctly interpreted (I used it to disable mod_rewrite in the playground folder too, in order to prevent WordPress’ rewrite rules – but since it had an error in it, the default WP rules were applied and no such page was found).

On a happier note, I just launched the “splash page” of an upcoming community website I’m working on, the one that pushed me to write the code for the vertical kwicks.

Vertical MooTools Kwicks (Fx.Elements), using relative sizes

I started out to make a vertical menu using Fx.Elements (instead of the classic horizontal one), for one of the sites I’m working on and, as always, I chose to use relatively sized elements (namely ‘em’).

However, although Fx.Base has support for specifying the unit, the original Kwicks demo doesn’t play well out of the box specifying ‘em’ as the unit.

Here’s a demo of what I did: vertical kwicks with em sized elements (notice the scalability of the layout – change the font size and it still works flawlessly)

The solution was to replace all occurences of .toInt() Continue reading