image
Blog Post • drupal

Javascript, jQuery, and jQuery UI (oh my!)

April 1, 2009by Tom Friedhof 1 min read
Blog Post • drupal
Javascript, jQuery, and jQuery UI (oh my!)
Back to top

I recently gave a talk at the local High Desert Drupal group that meets at the McDonalds in Apple Valley the first Wednesday of every month from 6pm - 8pm. There was a member in the group that wanted to implement tabs on her website.  I took the question and basically created a presentation around it.  I presented on building tab-based content the easy way, and then the hard way.  I basically showed how to do it by hand without a library, and then how to create tabs using a jQuery.  I also talked about Drupal.behaviors.

The Drupal.behaviors stuff is something that I brought home from attending the recent DrupalCon in Washington DC.  I'd heard of this namespace, but wasn't sure exactly what it did or why it was used.  After attending a JavaScript session given by Konstantin Käfer, the seed was planted.  I didn't quite understand yet the power of Drupal.behaviors, but his presentation really peaked my interest.  I ended up talking with Nate Haug, the resident Drupal Javascript master, a little later and he really got me excited about what Drupal.behaviors did, it's kind of like livequery for jQuery, but allowing Drupal to handle attaching behaviors back to ahah requests. After a little more research on Drupal.behaviors I was sold, I saw the light.

I ended the High Desert Drupal meeting talking about Drupal.behaviors and my new way to invoke jQuery scripts using this technique.  There was audio recorded for this meet-up, so if you're interested in hearing the talk, feel free to listen below, just hit "play".  Thanks to Helior Colorado for recording the audio.

JavaScript is something that has become near and dear to me and it's a language that I want to spend much more time in.  You can do a lot by embracing a JavaScript library and the use of jQuery.  I highly recommend jQuery to anyone working with JavaScript, it will allow you to do some amazing things, without writing too much code.

Authored by