Hello, suppose I have a page HTML:
...
< TD><SELECT SIZE="1 "NAME="appoint" onchange="creerText(this) ">
<OPTION selected="">0</OPTION >
<OPTION>1</OPTION>
<OPTION>2</OPTION >
</SELECT></TD >...
I will wish that when the user selectionne a value (0,1 or 2) the function Javascript creerText() creates a zone of text (textarea)
below the selection (<select>) in same page HTML.
For example, I thought of following function JS:
function creerText(obj) {
var zoneText = obj.selectedIndex;
for all zoneText do:
create a textArea;
}
But here, I do not manage to make so that my zones of text appear below the zone of selection. Indeed, they appear in new HTML page.
In made, it is as if the utilsator built a "form dynamically".
For example, the user could say, I would like 2 zones of text, 3 drop-down menu of such size etc... and the page is built dynamically.
Is it possible with HTML AND Javascript, how doing?
Thank you,
Jean-Baptiste
...
< TD><SELECT SIZE="1 "NAME="appoint" onchange="creerText(this) ">
<OPTION selected="">0</OPTION >
<OPTION>1</OPTION>
<OPTION>2</OPTION >
</SELECT></TD >...
I will wish that when the user selectionne a value (0,1 or 2) the function Javascript creerText() creates a zone of text (textarea)
below the selection (<select>) in same page HTML.
For example, I thought of following function JS:
function creerText(obj) {
var zoneText = obj.selectedIndex;
for all zoneText do:
create a textArea;
}
But here, I do not manage to make so that my zones of text appear below the zone of selection. Indeed, they appear in new HTML page.
In made, it is as if the utilsator built a "form dynamically".
For example, the user could say, I would like 2 zones of text, 3 drop-down menu of such size etc... and the page is built dynamically.
Is it possible with HTML AND Javascript, how doing?
Thank you,
Jean-Baptiste