Kristian Nissen

Icon

my contemporary identity

Drupal 6 PHPUnit testing setup

Using PHPUnit or PHPSpec when developing Drupal modules has some obvious benefits; you don’t have to reload you entire website in a browser each time you want to test your module. Read the rest of this entry »

Filed under: code is poetry , , ,

Drupal Unit testing using PHPSpec

It took a couple of hours to get this up and running, but the following guidelines will help you setup a PHPSpec based testing environment which uses the same conventions regarding folder structure like we know and love it from Rails and Zend. Read the rest of this entry »

Filed under: code is poetry , , , ,

Building your own jQuery Accordion menu

Every now and then I find myself building my own versions of existing plugins, I’m not claiming that my plugins are better than the ones found at jqueryui, but sometimes I just don’t need all that flexibility and options that they have to offer, which is why I build my own slimmer versions of e.g. the accordion menu. Read the rest of this entry »

Filed under: code is poetry , ,

Drupal 6 and hook_form_FORM_ID_alter

Using hook_form_FORM_ID_alter makes it possible to hook into any drupal 6 form before it renders, that way you can add fields or manipulate existing fields before the form is presented to the end user. Read the rest of this entry »

Filed under: code is poetry , ,

JavaScript Event Driven Architecture

Uh yeah.. it sounds difficult to implement and even harder to grasp, but it isn’t, honestly, it’s a great way to reduce the complexity of your javascript RIA and increase maintainability by implementing loose coupling. Read the rest of this entry »

Filed under: code is poetry , ,