I'm doing some exercises trying to learn Javascript and I created a basic webform that will post form data and display the response in an iframe. ( the code is below)
I would like to add to this and store the response from the server in a variable as a string. How can this be done using plain Javascript? I understand that it would be much easier with JQuery but I want to learn the JS basics before I move onto JQuery.
Any help is appreciated.
<form action="http://BLANK.ASP" method="get" target="hiddenFrame"
<pre>
userID: <input type="text" name="userid"><br>
password: <input type="text" name="userpassword"><br>
<center>
<button type="submit">Submit</button>
</center>
</pre>
</form>
<iframe id="hiddenFrame" name="hiddenFrame" style="width:1000px">hi
</iframe>