how to make this code works if i used it inside update panel and some of the checkbox values will be disabled according to database field ..?
<p>This code works fine if i use this inside ssercontrol > panel and i have a checkboxes in table when no checkbox is checked its works fine .... but if i disabled and checked any of the textbox then this doesn't work .... in usercontrol why ? i didnt understand ..</p>

<pre><code>&lt;script type="text/javascript" language="javascript"&gt;
function checkboxChecked(){
    var allInputs = document.getElementsByTagName("input");

    for(var i=0; i&lt;allInputs.length; i++) {
         var chk = allInputs[i];
         if(chk.type == "checkbox" &amp;&amp; !chk.disabled &amp;&amp; chk.checked) {

            return true;
         } 
    }
 alert("OOps! You haven't selected all available checkboxes");
    return false;
}
&lt;/script&gt;
</code></pre>
