I have a very simple layout, part of it is as follows:
<td class="subset">
<form name="searchFrm" method="get" action="update.php">
<input type="text" name="search">
</form>
html
html
html
</td>
I want to replace everything after the form up to the td with new html loaded from a PHP Page.
eg: Changing it to:
<td class="subset">
<form name="searchFrm" method="get" action="update.php">
<input type="text" name="search">
</form>
New HTML from PHP
</td>
I know I can select the form using $( '[name="searchFrm"]' ) and load an external page using .load('new.php') but how do I remove the HTML after the form and then add the new html ?
I tried
$( '[name="searchFrm"]' ).after().load('new.php')
Which didn't help, is there any way to do this ? I'm not trying to add or remove individual rows, but replace HTML after an element with in a row.
Updated post with correct form name.
Thanks