How can I enter only numbers in TextBox using JavaScript without disable right click ?
- by Space Cracker
I want to allow numbers only to be allowed for a textbox and I already do it onkeydown event by allow only numbers and prevent ctrl+V but I have two problems :
if I make right click then paste so any char can be entered and I want a solution without disable right click by oncontextmenu="return false;"
if I drag and drop any text it will be entered
Is there any solution that can work in all browsers without problem ?