how can I check to see if my <select> element contains the multiple attribute
<p>hi I have tried many options to check if the multiple attribute is set in my select box but none have worked. I am trying to determine if the current select box that I am getting values from is a multiple select so far this is what I have tried:</p>

<pre><code>if($(":select[multiple]").length){
           alert("worked");
}
</code></pre>

<p>also</p>

<pre><code>if($("select").attr("multiple"){
           alert("worked");
}
</code></pre>

<p>also</p>

<pre><code>if($("select").attr("multiple") != 'undefined'{
           alert("worked");
}
</code></pre>

<p>html:</p>

<pre><code>&lt;select multiple="multiple" style="height:50px" class="classname" name="multi_values[]"&gt; 
 &lt;option value="blah"&gt;blah&lt;/option&gt; 
 &lt;option value="blah"&gt;blah&lt;/option&gt; 
 &lt;option value="blah"&gt;blah&lt;/option&gt;              
&lt;/select&gt;
</code></pre>
