my telephone number validation doesn't work and I don't know why. Submit should be active when number length is 9 or 10,in other case submit should be disabled.Here's the code
HTML body:
<body>
<input type="number" name="number-189" value="" class="example1" id="numertel" min="500000000" max="900000000" aria-invalid="false">
<input type="submit" value="Send" class="example" id="przycisk">
<script src="script.js"></script>
</body>
JS
var numertell = document.getElementById("numertel");
var numerlength = numertell.value.length;
if(numerlength==10 && numerlength==9)
document.getElementById("przycisk").disabled=false;
else
document.getElementById("przycisk").disabled=true;
&&== AND,||== ORif(numerlength==10 && numerlength==9)will always be false. the length can't be 9 AND 10 in the same time. Change it to ||