I have for example in mysql table: fruit_store id fruit price
and I have form like:
<a href="#" id="add_input">Add</a>
<a href="#" id="remove_input">Remove</a>
<form action="<?php $_SERVER['PHP_SELF'] ?>" method="POST">
<table id="workTbl">
<tr>
<td>Fruit</td>
<td>Price</td>
</tr>
</table>
<p><input name="submit" type="submit" id="submit_tbl" /></p>
</form>
and have jquery code:
$(function(){
$("#add_input").click(function(){
$("#workTbl").append("<tr><td><input name='fruit_input' type='text' /></td><td><input name='price_input' type='text' /></td></tr>");
});
$("#remove_input").click(function(){
$('#workTbl input:last').remove();
$('#workTbl input:last').remove();
})
});
I want to ask how to insert multiple inputs into mysql table fruit_store with one submit button or multiple forms i don't know help me please!