[Solved] Why can’t I get the value of input element [closed]


its document.getElementById not document.getElementByID javascript is Javascript is case sensitive

var un = document.getElementById('user').value;
var pw = document.getElementById('pass').value;

not

var un = document.getElementByID('user').value;
var pw = document.getElementByID('pass').value;

solved Why can’t I get the value of input element [closed]