I have the following set up in html
<input maxlength="1" type="number" min="1" max="4" id ="c0r0"></input>
this has a text box where I can select a number 1 to 4 if I select a number I want it in my js file as a variable
I have tried this in my js file:
var tt = document.getElementsByTagName("input")[0].value;
console.log(tt);
I need it tt var be equal to the input. Do I need to add a button to submit my input? or once I select 1 through 4 my js file can grab the value