jquery multiselect checkbox values
<p>I'm using the Jquery multiselect checkbox plugin and am getting an error when converting the returned (CSV) values into an array.  While this is not, strictly, a jQuery question it seems to throw an error on a standard js method. 
Heres what I have:</p>

<pre><code>$(function(){
    $("select").multiselect({
         click: function(e){
            if( $(this).multiselect("widget").find("input:checked").length &gt; 4 ){
                return false;
            }
        },
        close:function(evt, ui) {                   // Get the selected values upon close
            var which = $(this).attr('id');         // Find out which selectbox was open
            var checkedVals = $('#'+which).val();   // Get CSV string of checked options
            var valArray = checkedVals.split(',');  // convert CSV string to array
                for(a in valArray) {
                    currentBox = ('#'+which+'Box');         // Find current selectbox wrapper
                    var eHeight;                            
                    eHeight = $('p'+currentBox).height();   // Current wrapper height
                    $('p'+currentBox).height(eHeight+18);   // Add 18px to current wrapper for each Value
                    $('p'+currentBox).append('&lt;div style="line-height:18px; margin-left:90px;"&gt;&lt;a href="#"&gt;&lt;img class="deleteVal" src="images/closewin.png" align="texttop" border="0"&gt;&lt;/a&gt; '+valArray[a]+'&lt;/div&gt;');
                }
        }
    }).multiselectfilter();
</code></pre>

<p>I get back a comma separated string which I want to put into an array using js.
The error - "checkedVals.split is not a function" - is thrown at this line:
var valArray = checkedVals.split(',');</p>
