<html>
<head>
<title></title>
</head>
<body>
脚本说明:
把如下代码加入<body>区域中
<SCRIPT language=JavaScript1.2>
<!--
var x =0
var y=0
drag = 0
move = 0
window.document.onmousemove = mouseMove
window.document.onmousedown = mouseDown
window.document.onmouseup = mouseUp
window.document.ondragstart = mouseStop
function mouseUp() {
move = 0
}
function mouseDown() {
if (drag) {
clickleft = window.event.x - parseInt(dragObj.style.left)
clicktop = window.event.y - parseInt(dragObj.style.top)
dragObj.style.zIndex += 1
move = 1
}
}
function mouseMove() {
if (move) {
dragObj.style.left = window.event.x - clickleft
dragObj.style.top = window.event.y - clicktop
}
}
function mouseStop() {
window.event.returnValue = false
}
function Show(divid) {
divid.filters.revealTrans.apply();
divid.style.visibility = "visible";
divid.filters.revealTrans.play();
}
function Hide(divid) {
divid.filters.revealTrans.apply();
divid.style.visibility = "hidden";
divid.filters.revealTrans.play();
}
//-->
</SCRIPT>
<DIV id=READ style="FILTER: revealTrans(transition=23,duration=0.5) blendTrans(duration=0.5); LEFT: 100px; POSITION: absolute; TOP: 75px; WIDTH: 600px; Z-INDEX: 10">
<center>
<table width="90%" border=1 cellpadding="0" cellspacing="0" bordercolorlight="#5E9BF7" bordercolordark="#FFFFFF" >
<tr bgcolor="#ffedc8">
<td colspan="1"><DIV onmouseout=drag=0 onmouseover="dragObj=READ; drag=1;move=0">标题栏 </div></td>
<td width=1%><A href="javascript:void(Hide(READ))">■</A></td></tr>
<tr>
<td colspan="4" bgcolor=#cccccc>
<table width=100% border=0 cellspacing=4>
<tr>
<td>
<font color=Blue>一个可以拖动和关闭的层,有意思的是它每次关闭的效果都不一样。不信的话,你自己试试吧
</td></tr></table></td></tr>
</table>
</div>
</body>
</html>