Hello, I am here again and I explain you my problem:
This table has the option to select the required row through a radio
button. But the problem is that if I sort the table (by any column) after
selecting some row, the selection goes off.
I think that maybe I can use the sortStart and sortEnd triggers to
maintain the state of the radio buttons in the table after sorting, but I`m
still having problems.
$("#tarjetas").tablesorter({widgets: ['zebra']});
<table id="tarjetas" class="tablesorter" align="center" width="100%">
<tr>
<td> </td>
<td><a href="#">Tarjeta</a></td>
<td ><a href="#">Descripción</a></td>
</tr>
<tr>
<td id="CreditCardIndex" width="30">
<input type="radio" id="CreditCardIndex" name="CreditCardIndex"
onclick="chequearRadio();" >
</td>
<td ><wfs:wfwrite name="CreditCardBeanCollection"
property="formatedNumber" scope="page"/></td>
<td ><wfs:wfwrite name="CreditCardBeanCollection" property="description"
scope="page"/></td>
</tr>
</table>
function chequearRadio() {
for (var i=0;i<document.formaSelectCard.elements.length;i++) {
var e = document.formaSelectCard.elements[i];
if ((e.type == objectType)&&(e.checked)){
document.formaSelectCard.selectedIndex.value = e.value;
}
}
}
Can anybody help me with this?
Thanks a lot!
Soledad.