summaryrefslogtreecommitdiffstats
path: root/js/jquery.multi-select.1.6.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/jquery.multi-select.1.6.js')
-rw-r--r--js/jquery.multi-select.1.6.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/js/jquery.multi-select.1.6.js b/js/jquery.multi-select.1.6.js
index 917f13a..95360d6 100644
--- a/js/jquery.multi-select.1.6.js
+++ b/js/jquery.multi-select.1.6.js
@@ -1,5 +1,7 @@
(function($){
var msMethods = {
+
+
'init' : function(options){
this.settings = {
disabledClass : 'disabled'
@@ -14,7 +16,7 @@
multiSelects.each(function(){
var ms = $(this);
ms.val(null);
- ms.attr('id', ms.attr('id') != undefined ? ms.attr('id') : 'ms-'+Math.ceil(Math.random()*1000));
+ ms.attr('id', ms.attr('id') ? ms.attr('id') : Math.ceil(Math.random()*1000));
var container = $('<div id="ms-'+ms.attr('id')+'" class="ms-container"></div>'),
selectableContainer = $('<div class="ms-selectable"></div>'),
selectedContainer = $('<div class="ms-selection"></div>'),
@@ -69,7 +71,7 @@
selectedUl = $('#ms-'+ms.attr('id')+' .ms-selection ul'),
selectableLi = selectableUl.children('li[ms-value="'+value+'"]');
- if (selectableLi.prop('disabled') == undefined){
+ if (!selectableLi.prop('disabled')){
selectableLi.hide();
ms.val(newValues);
if(titleAttr){