I'm working on project that is build on Wordpress (I'm using WP because of friendly permissions and rights system) and basically it's written by myself in PHP with a few javascript elements on my own single-pages. Now I need your help. I generate two forms by my PHP script. The template of each form is in MySQL DB table. It's because of friendly editing and administration for each particular row in each form for my not-very-skilled-with-pc collegues that need edit forms without my help. So I have some administration page for forms, collegue makes some changes, save it and script will generate edited form. It works perfectly. Script generate something like below (don't look at messy code, it's only beta without css etc.)
<form id="f1" method="POST" class="form-product-item" style="display: block;">
<fieldset form="f1" name="f1_f">
<legend> FORM 1 </legend>
<table style="width: 320px; max-width: 320px; float: left; margin: 5px">
<tr class="optional f1r1" name="f1r1_v" style="display: block;" >
<td style="width: 120px; min-width: 120px; max-width: 120px; height: 48px; max-height: 48px;">
<div class="optional f1r1" name="f1r1_v" style="display: block;" class="hidden-txt">Row 1 Form 1: </div>
</td>
<td style="width: 140px; min-width: 140px; max-width: 140px">
<input type="text" class="optional f1r1" name="f1r1_v" style="display: block;" class="hidden-txt" placeholder="Row 1 Form 1" size="15" />
</td>
<td style="width: 60px; max-width: 60px; max-width: 60px">suffix</td>
</tr>
</table>
<div style="clear: both"></div>
</fieldset>
<form id="f2" method="POST" class="form-product-item" style="display: block;">
<fieldset form="f2" name="f2_f">
<legend> FORM 2 </legend>
<table style="width: 320px; max-width: 320px; float: left; margin: 5px">
<tr class="optional f2r1" name="f2r1_v" style="display: block;" >
<td style="width: 120px; min-width: 120px; max-width: 120px; height: 48px; max-height: 48px;">
<div class="optional f2r1" name="f2r1_v" style="display: block;" class="hidden-txt">Row 1 Form 2: </div>
</td>
<td style="width: 140px; min-width: 140px; max-width: 140px">
<select id="f2r1_dm" name="f2r1_v" style="width: 120px">
<option selected>- Choose -</option>
<option>Option 1</option>
<option>Option 2</option>
</select>
</td>
<td style="width: 60px; max-width: 60px; max-width: 60px">suffix</td>
</tr>
<tr class="optional f2r2" name="f2r2_v" style="display: block;" >
<td style="width: 120px; min-width: 120px; max-width: 120px; height: 48px; max-height: 48px;">
<div class="optional f2r2" name="f2r2_v" style="display: block;" class="hidden-txt">Row 2 Form 2: </div>
</td>
<td style="width: 140px; min-width: 140px; max-width: 140px">
<input type="text" class="optional f2r2" name="f2r2_v" style="display: block;" class="hidden-txt" placeholder="Row 2 Form 2" size="15" />
</td>
<td style="width: 60px; max-width: 60px; max-width: 60px">suffix</td>
</tr>
<div style="clear: both"></div>
</table>
</fieldset>
Now I want to ask you friends, how to make one independent submit button below "FORM 2" (outside from form tags) that submit values from all fields from both forms at once and insert it to DB. I tried some advises I found here on stackoverflow but they did not work for me. I'm quite begginer with PHP and Java, AJAX I know very cursorily. So, for some advice or step by step tutorial I'll be very appreciate. Thank you very much for any help ;).