总结js实现验证html文本框输入只能为数字(html文本框只允许输入数字) 总结js实现验证html文本框输入只能为数字 第一种:输入整形判断functiongetEvent(){if(document.all){returnwindow.event;}//foriefunc=getEvent.caller;while(func!=null){vararg0