标签:输入 键盘 ret event code tag value his als
$(‘#lottoStage‘).keydown(function(){
if(event.keyCode == 46 || event.keyCode==8){
$(this).val(‘‘);
return true;
}
if(!(event.keyCode==46)&&!(event.keyCode==8)&&!(event.keyCode==37)&&!(event.keyCode==39)){
if(!((event.keyCode>=48&&event.keyCode<=57)||(event.keyCode>=96&&event.keyCode<=105))){
event.returnValue=false;
}
}
});
标签:输入 键盘 ret event code tag value his als
原文地址:http://www.cnblogs.com/austinspark-jessylu/p/6136974.html