87,910
社区成员
发帖
与我相关
我的任务
分享
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无定义 HTML 的 Event 事件</title>
<style type="text/css">
.photo {
position: relative;
}
.note {
position: absolute;
left: 0px;
top: 0px;
}
#addnote {
position: absolute;
left: 75px;
top: 75px;
}
#contentofnote {
position: relative;
border: 3px solid white;
cursor: move;
height: 50px;
width: 50px;
}
</style>
</head>
<body>
<div class="photo"><img src="http://baike.baidu.com/pic/4/11704969655851825.jpg" id="photo" /><div id="addnote"><div id="contentofnote" onmousedown="alert('x');"> </div></div></div>
</body>
</html>
<div id="addnote"><div id="contentofnote" onmousedown="alert('x');">
<div style="width:100%;height:100%;background:red;filter:alpha(opacity=0);"> </div>
</div></div>