日期:2014-05-17 浏览次数:20502 次
<script type="text/javascript">
$(function () {
$(".test").dblclick(function () {
location.href = "http://csdn.net";
// window.open();
});
});
</script>
</head>
<body>
<form id="form1" runat="server">
<div class="test" style=" width:200px; height:200px; background-color:#000000; cursor:pointer;" title="请双击">
</div>
</form>
</body>
</html>
<script type="text/javascript">
function test()
{
alert("双击了");
}
</script>
<div ondblclick="test()" style="width:500px; border:solid 1px red; height:300px">
在此区域双击
</div>
function test()