超简单的对联代码 suyongtao进来
看看有没有更简单的 适应1024--800分辨率调节 不挡东西[CODE]
<script language="JavaScript">
function ppp(){
num=(document.body.clientWidth-760)/2
num1=num-110;
if(num>0) num2=num+770;
else num2=770;
dlian1.style.left=num1;
dlian2.style.left=num2;
}
function sop(){
clearInterval(h);
dlian1.style.display='none'
dlian2.style.display='none'
}
h=setInterval('ppp()',10);
</script>
<body leftmargin="0" topmargin="0">
<div id='dlian1' style='position:absolute; width:100; height:400; z-index:1; background-color: #0000FF; layer-background-color: #0000FF; border: 1px none #000000; left: 10; top: 10;'>
<table width="100" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="30" align="right"><a href="javascript:sop()" onClick=""><b class="clo">[关闭]</b></a>&nbsp;</td>
</tr>
</table>
</div>
<div id='dlian2' style='position:absolute; width:100; height:400; z-index:1; background-color: #0000FF; layer-background-color: #0000FF; border: 1px none #000000; left: 1200; top: 10;'><table width="100" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="30" align="right"><a href="javascript:sop()"><b class="clo">[关闭]</b></a>&nbsp;</td>
</tr>
</table>
</div>
[/CODE]
[此贴子已经被作者于2005-10-24 14:44:54编辑过]