沙頭角首頁深圳之家---Sha Tau Kok Yan Tian

2009/01/08 11:19
兼容IE6和firefox,简单,实用。
IE7没试过,有条件的可以试试。
附件:js+css整合包

<!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=utf-8" />
<title>无标题文档</title>
</head>
<style type="text/css">
#winpop { width:200px; height:0px; position:absolute; right:0; bottom:0; border:1px solid #999999; margin:0; padding:1px; overflow:hidden; display:none; background:#FFFFFF}
#winpop .title { width:100%; height:20px; line-height:20px; background:#09F; font-weight:bold; text-align:center; font-size:12px; color:#ffffff; }
#winpop .con { width:100%; height:80px; line-height:80px; font-weight:bold; font-size:12px; color:#FF0000; text-decoration:underline; text-align:center}
#winpop .con a:link,#winpop .con a:visited{ color:#F00; text-decoration:underline;}
#winpop .con a:hover{ color:#09F;}
.close { position:absolute; right:4px; top:-1px; color:#FFFFFF; cursor:pointer}
</style>
<script type="text/javascript">
function tips_pop(){
var MsgPop=document.getElementById("winpop");
var popH=parseInt(MsgPop.style.height);
   if (popH==0){
    MsgPop.style.display="block";
   show=setInterval("changeH('up')",2);
   }
else {
hide=setInterval("changeH('down')",2);
}
}
function changeH(str) {
var MsgPop=document.getElementById("winpop");
var popH=parseInt(MsgPop.style.height);
if(str=="up"){
   if (popH<=100){
   MsgPop.style.height=(popH+4).toString()+"px";
   }
   else{  
   clearInterval(show);
   }
}
if(str=="down"){
   if (popH>=4){
   MsgPop.style.height=(popH-4).toString()+"px";
   }
   else{
   clearInterval(hide);
   MsgPop.style.display="none";
   }
}
}
window.onload=function(){
document.getElementById('winpop').style.height='0px';
setTimeout("tips_pop()",80);
}
</script>
<body leftmargin="0" topmargin="0">
<div id="winpop">
<div class="title">短消息<span class="close" onClick="tips_pop()">×</span></div>
    <div class="con"><a href="http://www.shatoujiao.com" target="_blank">未读系统消息 (3)</a></div>
</div>
</body>
</html>

下载文件 (已下载 173 次)
  • 中查看更多“右下角弹出窗口(兼容火狐IE6)”相关内容
  • 中查看更多“右下角弹出窗口(兼容火狐IE6)”相关内容
  • 中查看更多“右下角弹出窗口(兼容火狐IE6)”相关内容
  • 中查看更多“右下角弹出窗口(兼容火狐IE6)”相关内容
  • 中查看更多“右下角弹出窗口(兼容火狐IE6)”相关内容
  • 中查看更多“右下角弹出窗口(兼容火狐IE6)”相关内容
  • 发表评论
    表情
    emotemotemotemotemot
    emotemotemotemotemot
    emotemotemotemotemot
    emotemotemotemotemot
    emotemotemotemotemot
    打开HTML
    打开UBB
    打开表情
    隐藏
    记住我
    昵称   密码   游客无需密码
    网址   电邮   [注册]