在WEB服务器上可以设置使用网页过期可能效果更好
下面代码供参考<script>
var backspace=false;
    document.onkeydown=function (){
        if(window.event.keyCode==8&&!backspace){
            return false;
        }else{
            return true;
        }
     }
    document.onmousedown=function (e){
        e=e||window.event;   
        if((e.srcElement||e.target).tagName=="INPUT"){
            alert("Allow to do something");
            backspace=true;
        }
        alert(backspace.toString());
    }
    function lock(){
        backspace=false;
    }
</script>
<input type="text" onblur="lock();"></input>