0
I want a logic for html page. I made a form,and if user enters any numeric value in text field a dialog box should apear
3 Respuestas
+ 5
You can have an onChange event listener on input
Whenever input field data changes your event listener will be called.
Inside that you can check for ASCII values of keypressed..If ASCII lies between what you want open dialog box else not.
+ 2
<input onkeypress="checkInput()">
<script>
function checkInput(){
if(event.keyCode>=48 && event.keyCode<=57){
prompt("Enter Something");
}
}
</script>
0
can u post code for that.. i will be thankful