<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=GBK" />
<title>div 触发失去焦点事件</title>
</head>
<body>
<h1>设置tabindex属性可触发焦点事件</h1>
<div style="float:left;">
<div id="birthday__jQSelect0" class="dropdown" tabindex="0">
<div>
测试一下
</div>
</div>
<script type="text/javascript">
document.getElementById('birthday__jQSelect0').onblur = function(){
alert('div blur');
return false;
}
</script>
</body>
</html>
div 触发失去焦点事件
最新推荐文章于 2024-08-04 18:23:42 发布