Can anyone tell me why when using $('tr').slideDown('slow'); it causes the table row to forget its width, height etc.
and if there is a way to fix it?
Can anyone tell me why when using $('tr').slideDown('slow'); it causes the table row to forget its width, height etc.
and if there is a way to fix it?
 
    
     
    
    I fixed same problem with adding div into current table row->cells(TR->TD).
My sample table:
<table>
<tr id='row_1'>
   <td><div>element 1</div></td>
   <td><div>element 2</div></td>
   <td><div>element 3</div></td>
</tr>
<tr id='row_2'>
   <td><div>element 1</div></td>
   <td><div>element 2</div></td>
   <td><div>element 3</div></td>
</tr>
<tr id='row_3'>
   <td><div>element 1</div></td>
   <td><div>element 2</div></td>
   <td><div>element 3</div></td>
</tr>
</table>
Then if you need this make:
$('#row_1').slideDown(); // Make this onclick or some other event
$('#row_1').slideUp(); // Make this onclick or some other event
You must do:
$('#row_1 div').slideDown(); // Make this onclick or some other event
$('#row_1 div').slideUp(); // Make this onclick or some other event
Some lines of code more, but didnt found other way to solve this.
 
    
     
    
    I suspect it's because jQuery animation code tends to assume it can use display: block for elements that seem like they're block-level elements. For a <tr> that'd be bad, because it wants to be display: table-row (I think; something like that).
