~spreadubuntu/spreadubuntu/devel-drupal6

« back to all changes in this revision

Viewing changes to misc/form.js

  • Committer: ruben
  • Date: 2009-06-08 09:38:49 UTC
  • Revision ID: ruben@captive-20090608093849-s1qtsyctv2vwp1x1
SpreadUbuntu moving to Drupal6. Based on ubuntu-drupal theme and adding our modules

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// $Id: form.js,v 1.1 2007/09/12 18:29:32 goba Exp $
 
2
 
 
3
Drupal.behaviors.multiselectSelector = function() {
 
4
  // Automatically selects the right radio button in a multiselect control.
 
5
  $('.multiselect select:not(.multiselectSelector-processed)')
 
6
    .addClass('multiselectSelector-processed').change(function() {
 
7
      $('.multiselect input:radio[value="'+ this.id.substr(5) +'"]')
 
8
        .attr('checked', true);
 
9
  });
 
10
};