Darren Mothersele

London-based Drupal Web Developer

TL;DR

Drupal is a good choice as a platform for building web apps thanks to devops advances that work around PHP's inadequacies as a modern programming language. Web app builders can benefit from the extensive ecosystem of Drupal modules, and the unrivalled community support, while still complying (almost) with the best practises for web apps set out in the Twelve Factor web app methodology.

TL;DR: A few ideas kept repeating all weekend: Mobile first (actually content first) is the way to go. Design for the future (use web standards). Programming/mathematics helps with design. Photoshop is fiction (avoid it). Build prototypes not wireframes. Plus, possibly the world's first live commit of a large patch to Drupal core preformed live on stage in a nightclub to a huge cheer.

Videos of the sessions from Drupal Camp London have started to appear on YouTube including some vox-pops style interviews from attendees. In this short interview [YouTube], MySQL co founder David Axmark gives a warning to the Drupal community.

This last weekend was the hugely successful (and first ever!) Drupal Camp London. We had the Drupal Con in London a couple of years ago, and that was an amazing event, but somehow I enjoyed this even more. I think it was a much more manageable size, smoothly executed, and well focused. A big congratulations to the organisers. I've written up my notes from the weekend, with a bit from memory where I lost some of Saturday thanks to Evernote's security breach.

Business Day

I recently got asked by a fellow Mac user if I could recommend an IDE setup for Drupal development. I'm not really a fan of IDEs, but I have a setup that works really well for me. It might not be "integrated", but it certainly is a "development environment".

Live blogging, like you see on the Guardian or other news sites during important events is easily achieved on your Drupal sites, with a bit of jQuery AJAX and some EntityFieldQuery magic...

A while ago I was working on a migration from Open Atrium (Drupal 6) to Drupal 7. I decided to use the Migrate module for this, as it provides a great framework for building migrations. Unfortunately the Migrate module doesn't (at the moment) support migrating of node revisions. There's discussion on the issue queue about migrating revisions here. I quickly hacked together some working code that worked for me. I'm going to assume some prior knowledge of the Migrate module. If it's new to you, check out this presentation from Drupalcon Dever which gives a good overview of the architecture. Read on for more details, and code...

Customising Drupal forms is easy thanks to hook_form_alter(), unless you're working with form elements generated by Drupal 7's Field API. It's common to do customisations, add jQuery UI behaviours, or even advanced form item manipulation using a form alter hook, and Drupal makes it easy by giving your custom code access to the full form array and form state via the form alter hooks, but when you're dealing with Field API generated form fields, you will find it's not quite enough. The problem is that at the time the form alter hook is executed, the field API items in the form haven't been fully built yet. The solution to this is straight forward, and involves the use of a callback function that is called once the form build process is complete. Read on for full details and example code...

So, since recording that screencast that I never posted I have revised the example a little bit. Rather than re-record the screencast, as I don't have much time. I've posted the code to GitHub - as requested in the comments on the original post. To get up and running checkout the GitHub project for the example, or read on for more details...

I'm using an Aegir based hosting system for Drupal sites, and I've needed to do a couple of configuration tasks on certain sites. Rather than just hack the configuration generated by Aegir, or hard code this in (and have to do the same each time I need it), I have put this in two simple modules. The first allows you to specify IP address that can access the site, the second applies some simple htaccess rules to harden up security. Get them from my GitHub, or read on for more details...

Pages

Subscribe to Darren Mothersele RSS