IE 7 not selecting all rows generated by Php and called with jquery function
<p>Hey all, I have a form that is created by php. It contains all the users incoming emails. Each row has a checkbox, along with all the other user info. Firefox works like a charm, but IE has trouble selecting all the checkboxes. Only the first 2 get selected?????
The structure is like so:</p>

<p>PHP and HTML code:</p>

<pre><code>$this-&gt;requestsMail .='&lt;form name="selectDelete" class="selectDelete"&gt;
&lt;table id="inboxTable" class="txt13" width="800px"&gt;
&lt;tr&gt;&lt;th align="left" style="text-decoration:underline"&gt;&lt;input type="checkbox" name="selectAll" class="selectAll"/&gt;&lt;/th&gt;
    &lt;th style="text-decoration:underline"&gt;From&lt;/th&gt;&lt;td width="20px"&gt;&lt;/td&gt;&lt;th style="text-decoration:underline"&gt;Subject
    &lt;/th&gt;&lt;td width="20px"&gt;&lt;/td&gt;
    &lt;th style="text-decoration:underline"&gt;Date&lt;/th&gt;&lt;td width="20px"&gt;&lt;/td&gt;
    &lt;th style="text-decoration:underline"&gt;Action&lt;/th&gt;&lt;/tr&gt;';

    $classCounter=0;
while($info=mysql_fetch_array($result)){
    $sender=$info['sender'];
    $date=date("m/d/y- h:i:s A",$info['date']); //takes timeStamp in db &amp; converts to m/d/y - time
    $subject=$info['subject'];
    $message=$info['message'];
    $id = $info['id'];


    $this-&gt;requestsMail .='
    &lt;tr&gt;
    &lt;td width="20px"&gt;&lt;input type="checkbox" name="delID" class="delID" value="'.$id.'"/&gt;&lt;/td&gt;
    &lt;td align="center" width="150px"&gt;&lt;a href="profile.php?username='.$sender.'"&gt;'.substr($sender,0,18).'&lt;/a&gt;&lt;/td&gt;
    &lt;td width="20px"&gt;&lt;/td&gt;
    &lt;td align="left" width="100px" height="20px"&gt;'.substr($subject,0,18).'&lt;/td&gt;
    &lt;td width="20px"&gt;&lt;/td&gt;
    &lt;td align="center" width="150px"&gt;'.$date.' - '.$hours.'&lt;/td&gt;
    &lt;td width="20px"&gt;&lt;/td&gt;
    &lt;td width="100px"&gt;
    &lt;a href="#" class="showMail"&gt;read&lt;/a&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="7"&gt;
&lt;div class="displayMail" style="display:none; margin:10px 60px 10px 80px" &gt;

    &lt;!--Display user message--&gt;
    &lt;div align="left" class="mainContent"&gt;
        &lt;div align="center" id="postContent"&gt;                        
            &lt;table id="userPost" width="590px"&gt;
                &lt;tr&gt;
                    &lt;td width=100&gt;'.$dbConn-&gt;getUserSimplePic($sender).'&lt;/td&gt;
                    &lt;td&gt;
                        &lt;div style="text-align:right; margin:0px 25px 15px 0px;"&lt;span class="smallTxt"&gt;&lt;a href="'.$id.'" class="delMail"&gt;Delete&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;
                        &lt;div class="message" style="margin:5px 15px;"&gt;'.$message.'&lt;/div&gt;
                        &lt;div class="sender" style="text-align:right; margin:15px 50px 0px 50px;"&gt;-&lt;span class="smallTxt"&gt; '.$sender.' @ '.$date.'&lt;div&gt;&lt;a href="#" class="replyLink"&gt;reply&lt;/a&gt;&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;
                    &lt;/td&gt;
                &lt;/tr&gt;
            &lt;/table&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;&lt;!--end displayMail--&gt;

&lt;/td&gt;&lt;/tr&gt;
    &lt;!-- Confirm delete?--&gt;
    &lt;tr&gt;&lt;td colspan="7" align="center"&gt;&lt;div class="confirmDelete" style="display:none; margin-bottom:50px; color:#ff8c00; font-size:18px;"&gt;
        Delete this email:&amp;nbsp;&amp;nbsp;&lt;a href="inbox" class="delLinkYes" title="Delete email!"&gt;Y&lt;/a&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;a href="#" class="delLinkNo" title="Do not delete."&gt;N&lt;/a&gt; ?
    &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;tr&gt;
    &lt;td colspan="7"&gt;
        &lt;div class="replyDiv" align="center" style="display:none; margin:10px 60px 10px 10px;"&gt;

            &lt;form width="350px" class="userReplyForm" name="userReplyForm" method="post" action="#"&gt;
            &lt;input type="hidden" class="date" name="date" value="'.time().'"/&gt;
            &lt;input type="hidden" class="sender" name="sender" value="'.$username.'"/&gt;
            &lt;input type="hidden" class="recipient" name="recipient" value="'.$sender.'"/&gt;
            &lt;table align="center" width="350px" class="smallTxt userDetails"&gt;
                &lt;tr&gt;
                    &lt;td align="left" width="350px"&gt;&lt;input type="text" class="subject" name="subject" size=30 value="RE:'.$subject.'"/&gt;&lt;/td&gt;&lt;/tr&gt;
                &lt;tr&gt;
                    &lt;td width="350px"&gt;&lt;textarea rows="6" cols="42" class="message" name="message"&gt;&lt;/textarea&gt;&lt;/td&gt;&lt;/tr&gt;
                &lt;tr&gt;
                    &lt;td align="center"&gt;&lt;input type="submit" name="Submit" class="submitBtnSmallLong" value="Send Reply"/&gt;&lt;/td&gt;&lt;/tr&gt;
            &lt;/table&gt;
            &lt;/form&gt;

        &lt;/div&gt;
        &lt;div class="emailSent" align="center" style="display:none; margin:10px 60px 10px 10px; color:blue; font-size:18px;"&gt;
        &lt;/div&gt;
    &lt;/td&gt;
&lt;/tr&gt;

    ';
$classCounter = $classCounter + 1;
}

      $this-&gt;requestsMail .='       
      &lt;tr&gt;
        &lt;td colspan="2"&gt;&lt;input type="button" class="submitBtnSmallXtraLong" value="Delete selected" name="delSelectedSentMail" /&gt;&lt;/td&gt;
        &lt;td&gt;&lt;input type="hidden" class="inboxOutbox" value="inbox"/&gt;&lt;/td&gt;
        &lt;td colspan="3"&gt;&lt;div id="delStatus"&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
      &lt;/table&gt;&lt;/form&gt;&lt;br/&gt;&lt;br/&gt;&lt;!--&lt;div class="dashed"&gt;&lt;/div&gt;--&gt;'; 
</code></pre>

<p>Then I use jQuery to let the user select which emails to delete, either:
1.) Individually by record OR
2.) By clicking on the checkbox contained in the "th" tag, which is "supposed" to select ALL the other checkboxes.</p>

<p>The problem is that everything works fine in Firefox, but IE has trouble in selecting all the rows. Only the first 2 checkboxes (the one contained in "th" tag &amp; the first record) respond to the select all function. The rest do not get selected. I gave each input a class  and not an ID, so this should not cause the issue. Any ideas why IE behaves like this????</p>

<p>Note: I can select the checkboxes individually, but not all at once in IE.</p>

<p>jquery code:</p>

<pre><code>        $(".selectAll").unbind("click").click(function(e){//Method to get ALL checkboxes at once
        var parentForm = $(this).closest("form"); //get current form handle
        var bool = $(this).is(":checked"); //gets whether selected or not
        //var listSent = new Array();
        var listSent = [];

        $(function(){ //check or uncheck based on root checkbox status
            $(parentForm).find("input:checkbox").attr("checked", bool); //have to use parentFormHandle otherwise goes into next form

            if(bool === true){
            $(parentForm).find(".delID").each(function(index,element){ //uses parentForm to restrict to current working form
                listSent.push( $(this).val());
            }); }

            //display all values in array
            $(".submitBtnSmallXtraLong").unbind("click").click(function(a){
                var selectedBox = $(this).closest("tr").find(".inboxOutbox").val(); //are we to delete from inbox or outbox?
                var delStatHandle = $(this).closest("tr").find("#delStatus");   //handle for delStatus 
                    //alert(selectedBox); return false;

                if(listSent.length &gt;= 1){
                        $(".submitBtnSmallXtraLong").css("background-color","#cccccc").attr("disabled",true);

                        var dataString = "data=" + listSent + "&amp;messageType=" + selectedBox;
                            $.ajax({
                                type: "POST",
                                url:  "ajaxDelSentMailBatch.php",
                                data:  dataString,
                                dataType: "JSON",
                                cache: false,
                                success: function(data){ 
                                    if(data == "true"){//tell user deletion successful
                                        $(delStatHandle).append("Deleted!").fadeIn("slow");
                                        setTimeout(function(){
                                            $(delStatHandle).fadeOut("slow");
                                            location.reload();
                                        },800); 
                                        $(".submitBtnSmallXtraLong").css("background-color","#cecece").attr("disabled",false);
                                    }else{
                                    $("#delStatus").append("Failed to Delete Email/s!").fadeIn("slow");
                                        setTimeout(function(){
                                            $(delStatHandle).fadeOut("slow");
                                            location.reload();
                                        },800); 
                                    $(".submitBtnSmallXtraLong").attr("disabled",false);
                                    }
                                }
                            });

                }
            });

        });
    });
</code></pre>

<p>Any suggestions why IE is acting up?</p>
