支持w3c标准的浮动QQ在线客服代码

来源:互联网 发布:php 页面跳转并传参数 编辑:程序博客网 时间:2024/05/02 03:07

演示地址:http://www.96kb.com/uploadfile/res/code/qq2/

源码是:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>QQ在线客服</title>
<style type="text/css">
<!--
a:link {
 color: #000000;
 text-decoration: none;
}
a:visited {
 text-decoration: none;
 color: #000000;
}
a:hover {
 text-decoration: none;
 color: #FF0000;
}
a:active {
 text-decoration: none;
}
a {
 font-size: 9pt;
}
body,td,th {
 font-size: 9pt;
}
-->
</style>
</head>
<body>
<!--在线QQ -->
<DIV id="STATICMENU" style="Z-INDEX:999; LEFT:0px; VISIBILITY: visible; WIDTH: 76px; POSITION: absolute;TOP:274px; HEIGHT: 203px">
  <table width="100" border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td colspan="3" style="width:106px; height:40px; background-image:url(images/qq/QQ_3.jpg);"><div style="position:absolute; width:22px; height:21px; right:-25px; cursor:pointer; top:0px;" onClick="gogo();" title="点击关闭该滚动窗口!"></div></td>
    </tr>
    <tr>
      <td width="4" height="78" background="images/qq/QQ_8.gif"></td>
      <td width="98" align="center"><TABLE cellSpacing=0 cellPadding=3 width="100%" bgColor=#ffffff>
          <TBODY>
            <TR>
              <TD width="30%"><DIV align=center><IMG src="images/qq/74_m.gif" width=20 height=20></DIV></TD>
              <TD width="70%"><A href="http://wpa.qq.com/msgrd?V=1&Uin=28298960&Site=http://www.96kb.com&Menu=no" target=_blank>在线咨询</A></TD>
            </TR>
            <TR>
              <TD><DIV align=center><IMG src="images/qq/49_m.gif" width=20 height=20></DIV></TD>
              <TD><A href="http://wpa.qq.com/msgrd?V=1&Uin=28298960&Site=http://www.96kb.com&Menu=no" target=_blank>在线咨询</A></TD>
            </TR>
            <TR>
              <TD><DIV align=center><IMG src="images/qq/51_m.gif" width=20 height=20></DIV></TD>
              <TD><A href="http://wpa.qq.com/msgrd?V=1&Uin=28298960&Site=http://www.96kb.com&Menu=no" target=_blank>在线咨询</A></TD>
            </TR>
            <TR>
              <TD><DIV align=center><IMG src="images/qq/57_m.gif" width=20 height=20></DIV></TD>
              <TD><A href="http://wpa.qq.com/msgrd?V=1&Uin=28298960&Site=http://www.96kb.com&Menu=no" target=_blank>在线咨询</A></TD>
            </TR>
          </TBODY>
        </TABLE></td>
      <td width="4" background="images/qq/QQ_7.gif"></td>
    </tr>
    <tr>
      <td colspan="3"><img src="images/qq/QQ_12.gif" width="106" height="44"></td>
    </tr>
  </table>
<SCRIPT language="javascript">
<!--
var stmnGAP1=70;
var stmnGAP2=100;
var stmnBASE=70;
var stmnActivateSpeed=200;
var stmnScrollSpeed=10;
var stmnTimer;
function RefreshStaticMenu()
{
 var stmnStartPoint,stmnEndPoint,stmnRefreshTimer; 
 stmnStartPoint=parseInt(STATICMENU.style.top,10); 
 stmnEndPoint=document.documentElement.scrollTop+stmnGAP2; 
 if(stmnEndPoint<stmnGAP1)stmnEndPoint=stmnGAP1; 
 stmnRefreshTimer=stmnActivateSpeed; 
 if(stmnStartPoint!=stmnEndPoint){
  stmnScrollAmount=Math.ceil(Math.abs(stmnEndPoint-stmnStartPoint)/15);  
  STATICMENU.style.top=parseInt(STATICMENU.style.top,10)+((stmnEndPoint<stmnStartPoint)?-stmnScrollAmount:
  stmnScrollAmount);  
  stmnRefreshTimer=stmnScrollSpeed;  
 }
 stmnTimer=setTimeout("RefreshStaticMenu();",stmnRefreshTimer); 
}
STATICMENU.style.top=document.documentElement.scrollTop+stmnBASE;
RefreshStaticMenu();
//-->
</SCRIPT>
<SCRIPT language="javascript">
function gogo(){
 STATICMENU.style.display='none'; 
}
</SCRIPT>
</DIV>
<!--在线QQ -->
</body>
</html>

原创粉丝点击