just teaching myself javascript and im trying to get my code to read in inputs from the user and then print them out into a text area but i have been unsuccessful thus far.
so far im just using the alert just to test that my code is storing the input in the array i ve set.
<HTML>
<HEAD>
<TITLE>Test Input</TITLE>
<SCRIPT LANGUAGE="JavaScript">
var TestVar = new Array();
var i = 0;
function testResults (form) {
TestVar[i] = form.inputbox.value;
alert ("You typed: " + TestVar[1]);
i++;
}
</SCRIPT>
</HEAD>
<BODY>
<FORM NAME="myform" ACTION="" METHOD="GET">Enter a name into the box: <BR>
<INPUT TYPE="text" NAME="inputbox" VALUE=""><P>
<INPUT TYPE="button" NAME="button" Value="Click"
onClick="testResults(this.form)">
<form name="myform" action="" method="POST">
<div align="center">
<textarea cols="40" rows="5" name="output">'Now we are inside the area - which is nice.' this.TestVar[i];</textarea>
</FORM>
</BODY>
</HTML>
I know its basic, but i cant seem to get it right, thanks for any help givin.