限制input只能输入数字

<input type="number" onkeyup="this.value=this.value.replace(/\D/g,'')">

猜你喜欢

转载自www.cnblogs.com/pcx105/p/12016387.html