jquery - Table row cell values update by using row number -


 $('#mytable').parent(rownum).parent().find(".one").text(name); <table id="mytable" class="mytable">                 <tr>                     <td class="mytd">name</td>                     <td class="mytd">age</td>                     <td class="mytd">gender</td>                     <td class="mytd">skills</td>                     <td class="mytd">note</td>                 </tr>                 <? while($row=mysql_fetch_array($res)){ ?>                 <tr>                                     <td class='one'><? echo $row["name"];?></td>                 <td class='two'><? echo $row["age"];?></td>                 <td class='three'><? echo $row["gender"];?></td>                 <td class='four'><? echo $row["skills"];?></td>                 <td class='five'><? echo $row["note"] ;?></td>                 <td><button id='edit' value='edit'>edit</button></td>                 <td><button value='delete' id='delete'>delete</button></td>                                  </tr>                 <? } ?>             </table>  

i want update selected tr cell value passing rownum parent updating cells of tr's.please help..

i think need this

$('#mytable tr').eq(rownum).find(".one").text(name) 

Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -