- 1
How do I read what's in an input box?
I'm trying to read what goes in these boxes https://code.sololearn.com/WieLsY81YbGM/?ref=app
5 Respuestas
+ 1
it might take some event to take input
ex-
in input tag write
oninput=" getval()"
in script tag
use this
function getval(){
var aval = document.querySelector("#A1").value ;
document.write(aval) ;
};
now as soon as you input a value in input box it will show you value
0
What do you want as a output?
And in your code line 36 is wrong in html section, it should be :
var A1 = document.getElementById("A1");
0
var box1Answer = parseInt(Math.random()*9)
0
TheCoolTroy i just told you
- 2
As my output I want what was typed into one of the boxes