onfocus在火狐、ie10浏览器失效解决方法方法
<script>
function setit(){
if(document.all){
document.getElementById("myframe").attachEvent("onfocus",dothis);
}else{
document.getElementById("myframe").contentWindow.addEventListener("onfocus",dothis,false);
}
}
function dothis(){
alert("blurred");
}
</script>
<body onload="setit()">
<input />
</body>