input number类型 长度限制
<input type="number" oninput="if(value.length>5)value=value.slice(0,5)">
限制input输入框只能输入数字
<input type="text" oninput = "value=value.replace(/[^\d]/g,'')">
<input type="number" oninput="if(value.length>5)value=value.slice(0,5)">
<input type="text" oninput = "value=value.replace(/[^\d]/g,'')">