jquery indexOf problem with IE
<p>I have a multiple select field and a jquery function that checks for a change in the select. the function looks for the value "Other", and if it's selected then displays an extra text field. </p>

<p>This is all working fine in chrome and FF, but for some reason IE throws an error on the indexOf function "Object doesn't support this property or method".</p>

<p>Any help would be much appreciated.</p>

<p>Here's the code:</p>

<p>EDIT: 
Remember that this code actually works in chrome and FF. Is only IE that is throwing the error...</p>

<pre><code>&lt;select name="test" multiple="multiple" id="test"&gt;
 &lt;option value="one"&gt;one&lt;/option&gt;
 &lt;option value="two"&gt;two&lt;/option&gt;
 &lt;option selected="selected" value="Other"&gt;Other&lt;/option&gt;
&lt;/select&gt;
&lt;input name="Name_Other" type="text" id="Name_Other" class="OtherDisplay" /&gt;


$.toggleOther = function (dd, txtOther) {
        if ($(dd).val() == null || $(dd).val().indexOf("Other") != 1) 
            $(txtOther).hide();

        $(dd).change(function () {
            var sel = $(this).val();
            if (sel != null &amp;&amp; sel.indexOf("Other") != -1) { 
                $(txtOther).show();
            }
            else {
                $(txtOther).hide();
            }
        });
    }

$.toggleOther("#test", ".OtherDisplay");
</code></pre>
