A complex CCK module in Drupal September 20th, 2007

CCK is Drupal’s way of making rich content. It means that nodes of any content type can have any kind of data attached to them, so you can have e.g. a directory of superstore outlets, where the outlet records have their longitude and latitude (editable by a Google Map widget) whereas the contact records (e.g. [...]

There seems no pirate because it be all pirate September 18th, 2007

I hope you all realise what day it is tomorrow. Kevin Reynen writes on the drupal.org development list:
It’s one thing to change your blog. It’s another to change all the sites of your coworkers browse!
http://greasemonkey.makedatamakesense.com/browse_like_a_pirate/

Rumour has it that this is how one of the original on-the-web site piratizers worked: it would translate your webpage [...]

If random is secure, pseudorandom is pseudosecure September 15th, 2007

Do you bank online? How are you asked for your secret code? Three randomly placed digits of it, hmm? The reason for the randomness is that any malicious keylogging software can’t see your screen, just your keyboard: so even if it logged every time you banked online, the fraudster it reported back to could never [...]

Barcamp left me with a sticky keyboard September 15th, 2007

The inevitable keyboard accident happened at Barcamp, although not as badly as I think Tristan Roddis suffered. A few teaspoons of a particularly sugary branded drink ended up under my arrow keys, which meant that pressing up became an unpleasant feedback experience. I should’ve asked people for advice at the time, to be honest: I [...]

Visualizing an application’s entire call stack September 5th, 2007

KentBye, Flickr user, has been playing with GraphViz. He’s used it to turn an XDebug output into a pretty visualization of Drupal’s call stack, or what functions call what functions during a typical Drupal request.

Drupal logins not working August 29th, 2007

There’s a long (and old) thread about Drupal logins not working. A lot of the problems are to do with weird PHP version changes; some of them are caused by cookie persistence; but the one we’ve had was the result of losing the login box on the front page.
“How can you log in without a [...]

Unobtrusive suggested input text with jQuery August 22nd, 2007

You can do this with any framework, of course, but I’ve just implemented a subtle piece of jQuery-supported code in my blog search to make the suggested text disappear when you focus into it, and re-fill an empty field with the suggested text when you move focus away from the box by clicking elsewhere. Give [...]

Image submit buttons in Drupal FAPI August 20th, 2007

Drupal 5.x’s FAPI doesn’t handle image buttons terribly well: here’s how to implement it with the #button_type property. And a minor refinement that Victoria and I implemented today at work.

OpenOffice arrows, .soe files and writing your own SVG August 1st, 2007

Creating your own arrows in OpenOffice (.org, 2.0) is a pain. There’s tutorials out there that claim to show how to create arrows from OOo diagrams, but I’ve not had much success with those. However, by taking apart an existing arrow, I’ve managed to work out the rather nasty syntax
OOo arrow libraries are suffixed .soe, [...]

Image manipulation in the browser June 6th, 2007

While Picnik gradually converts the functionality of desktop image processing software into online tools (in the hope, presumably, of being bought up by one of the big players), Flash has found other, more piecemeal uses in augmenting the image and font functionality of your average browser. Hot on the heels of sIFR, which replaces text [...]