Click to See Complete Forum and Search --> : dynamically add a new form to page with a button


bourniqc
07-10-2003, 03:41 PM
I would like to have a section of my web page that the user can create dynamically. I will have the inital form on the page. If they need to add another item (goal), I would like them to click on a button. Then a blank form would open below the intial form.



form code:

<html>

<head>
<title>ind goals</title>
</head>

<body 0nload="document.indgoalform.indbusplan.focus();">

<form onsubmit="return FrontPage_Form1_Validator(this)" name="FrontPage_Form1">
<div align="center"><center><table border="2" height="52" width="90%">
<tr align="center">
<font color="#000080" size="2"><td width="562" align="left">Departmental Goal()<p>(Business
plan goal reference number <input type="text" name="indbusplan" size="4" value=" ">).</p>
<p><textarea rows="3" name="indgoal" wrap="physical" cols="45"> </textarea></p>
<p>Individual Goal:</p>
<p><textarea rows="3" name="indgoalind" wrap="physical" cols="45"></textarea></p>
<p>Targets for 3 &amp; 4 ratings:</p>
<p><textarea rows="3" name="indtar" wrap="physical" cols="45"></textarea></p>
<p>Comments:</p>
<p><textarea rows="4" name="indcomments" wrap="physical" cols="44"> </textarea></font></td>
<td width="76"><!--webbot bot="Validation" startspan S-Display-Name="Department Goal (1)"
S-Data-Type="Number" S-Number-Separators=",." --><!--webbot bot="Validation" endspan --><input
type="text" name="indweight" size="4" value="0"></td>
<font color="#000080" size="1"><td width="221"><div align="left"><p>&nbsp;&nbsp;&nbsp; <input
type="radio" name="indrating" value="4">4 Far Above</p>
</div><div align="left"><p>&nbsp;&nbsp;&nbsp; <input type="radio" name="indrating"
value="3">3 Above</p>
</div><div align="left"><p>&nbsp;&nbsp;&nbsp; <input type="radio" name="indrating"
value="2">2 Met</p>
</div><div align="left"><p>&nbsp;&nbsp;&nbsp; <input type="radio" name="indrating"
value="1">1 Below</font></td>
</tr>
<tr>
<td width="562" align="left"><font color="#000080" size="2"><div align="center"><center><p><input
type="button" value="Add goal" name="Add goal" ></font></td>
<td width="76" align="center">&nbsp;</td>
<td width="221" align="center">&nbsp;</td>
</tr>
</table>
</center></div>
</form>

<p align="center">&nbsp;</p>
</body>
</html>



Cheryl