I need some help to insert some dynamic inputs to database..
What I need is that I have one table that will contain some details, and that insert should get a unique ID in the db. That is easy, but then the headache is in place, I need the dynamic inputs to get inserted into the database in a different table, and then I need them to be able to connect with the user who submitted them.
An example: I write in the details, and write some stuff in the dynamic inputs. And I submit it. Then I need to be able to see what user submitted what in the dynamic inputs.
Anyone willing to help me with this?
Here is the formcode:
<form method="post" action="./paamelding">
<p><label>Fult navn til grupperleder:</label></p>
<p><input type="text" name="fultnavn" /></p>
<p><label>Gruppeleders alder:</label></p>
<p><input type="text" name="alder" /></p>
<p><label>Gruppeleders telefon nummer:</label></p>
<p><input type="text" name="tlf" /></p>
<p><label>Gruppeleders epost adresse:</label></p>
<p><input type="text" name="epost" /></p>
<div id="dynamicInput">
<p><label>Deltaker 1:</label></p>
<p><input type="text" name="myInputs[]"></p>
</div>
<input type="button" value="Legg til et nytt felt" onClick="addInput('dynamicInput')" />
<button type="submit" name="group_submit">Send inn påmelding!</button>
</form>
Thanks a lot in advance!