Iam adding a new row on click of a button and that row contains 3 textboxes and one select buutton .How do I make the textboxes and select box values to null of that newly added row .
$('#table').find("sno_'+i'").val('');
Here “i ” is dynamically generated row.But this is not working.
If you’re appending it as the last row and you want to clear all the form element value, you could just do this:
If you need to limit it to the text and select inputs, do this:
Beyond that, your question is not very clear. If
iis the index of the row, then do:If
ihas been appended to a class on the row, then do this:If
ihas been appended to the ID attribute on the row, then do this: