javascript - ajax.actionlink insertionmode insertafter for table -
javascript - ajax.actionlink insertionmode insertafter for table -
if have table variable number of <tr> elements,
<table id="my_table"> <!--there 1 tr or 3, don't know, server decides based on database--> <tr> <td>a</td> <td>b</td> <td>c</td> </tr> </table> and have ajax.actionlink insertionmode.insertafter, want insert new <tr> target "my_table" or have target lastly <tr> have?
if it's latter, means i'll have give lastly <tr> element dynamically generated id value can access one, correct?
is there easier way this? or misunderstanding how insert after works?
you include hidden tr @ end of table , utilize insertionmode.replace
<table> <tr id='1'> <td>something</td> </tr> <tr id='replaceme' class='hidden'><tr> </table> don't forget replacement html should include <tr id='replaceme'>
the should have insertionmode.append , prepend
javascript html ajax asp.net-mvc
Comments
Post a Comment