Version compl�te: jsB@nk » Form » Textarea » Dynamic Input
URL: https://www.javascriptbank.com/dynamic-input.html
(Internet Explorer seulement) offre un forme avec autant de cases que l'utilisateur sélectionne. Après avoir entré le nombre de boîtes, de la forme est dynamiquement mis à jour alors que le reste de la formule reste inchangée.
Version compl�te: jsB@nk » Form » Textarea » Dynamic Input
URL: https://www.javascriptbank.com/dynamic-input.html
<SCRIPT LANGUAGE="JavaScript"><!-- Begin// Peter Hermus , http://come.to/speedpetefunction createForm(number) {data = ""; inter = "'";if (number < 16 && number > -1) {for (i=1; i <= number; i++) {if (i < 10) spaces=" ";else spaces=" ";data = data + "URL " + i + " :" + spaces+ "<input type='text' size=10 name=" + inter+ "url" + i + inter + "'><br>";}if (document.layers) {document.layers.cust.document.write(data);document.layers.cust.document.close();}else {if (document.all) {cust.innerHTML = data; } }}else {window.alert("Please select up to 15 entries."); }}// End --></script><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->
<form name=counter>Number of URLs to enter:<input type=text name=number size=5><input type=button value="Update" onClick="createForm(counter.number.value);"></form><br><form name="webform"><table border=0><tr valign=top><td>Name:</td><td><input type=text size=20 name=name onChange="msg(this.form)"></td></tr><tr><td colspan=2><!-- Placeholder for dynamic form contents --><span id=cust style="position:relative;"></span></td></tr><tr valign=top><td>Comments:</td><td><textarea name=comments cols=45 rows=5 wrap=virtual OnChange="msg(this.form)"></textarea></td></tr><tr><td></td><td><input type=submit value="Send"></td></tr></table></form><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->