落伍者(四季发财)
$_$专抢第二页第一帖$_$
![Rank: 4](static/image/common/star_level3.gif)
- 贡献
- 0
- 鲜花
- 1
- 注册时间
- 2002-11-23
|
发表于 2005-7-18 00:45:37
|
|阅读模式
来自 中国浙江温州
![](http://www.moyu.cn/duba.gif)
![](http://www.moyu.cn/qq.gif)
![](http://www.moyu.cn/qq2.gif)
![](http://www.moyu.cn/duba2.gif)
右下角 由下往上浮起代码 会自动关闭 具体请看下去
- <SCRIPT language=javascript>
- window.onload = enetgetMsg;
- window.onresize = enetresizeDiv;
- window.onerror = function(){}
- var enetdivTop,enetdivLeft,enetdivWidth,enetdivHeight,enetdocHeight,enetdocWidth,enetobjTimer,i = 0;
- function enetgetMsg()
- {
- try{
- enetdivTop = parseInt(document.getElementById("enetMeng").style.top,10)
- enetdivLeft = parseInt(document.getElementById("enetMeng").style.left,10)
- enetdivHeight = parseInt(document.getElementById("enetMeng").offsetHeight,10)
- enetdivWidth = parseInt(document.getElementById("enetMeng").offsetWidth,10)
- enetdocWidth = document.body.clientWidth;
- enetdocHeight = document.body.clientHeight;
- document.getElementById("enetMeng").style.top = parseInt(document.body.scrollTop,10) + enetdocHeight + 10;// enetdivHeight
- document.getElementById("enetMeng").style.left = parseInt(document.body.scrollLeft,10) + enetdocWidth - enetdivWidth
- document.getElementById("enetMeng").style.visibility="visible"
- enetobjTimer = window.setInterval("enetmoveDiv()",10)
- }
- catch(e){}
- }
-
- function enetresizeDiv()
- {
- i+=1
- if(i>800) enetcloseDiv() /自动关闭时间
- try{
- enetdivHeight = parseInt(document.getElementById("enetMeng").offsetHeight,10)
- enetdivWidth = parseInt(document.getElementById("enetMeng").offsetWidth,10)
- enetdocWidth = document.body.clientWidth;
- enetdocHeight = document.body.clientHeight;
- document.getElementById("enetMeng").style.top = enetdocHeight - enetdivHeight + parseInt(document.body.scrollTop,10)
- document.getElementById("enetMeng").style.left = enetdocWidth - enetdivWidth + parseInt(document.body.scrollLeft,10)
- }
- catch(e){}
- }
- function enetmoveDiv()
- {
- try
- {
- if(parseInt(document.getElementById("enetMeng").style.top,10) <= (enetdocHeight - enetdivHeight + parseInt(document.body.scrollTop,10)))
- {
- window.clearInterval(enetobjTimer)
- enetobjTimer = window.setInterval("enetresizeDiv()",1)
- }
- enetdivTop = parseInt(document.getElementById("enetMeng").style.top,10)
- document.getElementById("enetMeng").style.top = enetdivTop - 1
- }
- catch(e){}
- }
- function enetcloseDiv()
- {
- document.getElementById('enetMeng').style.visibility='hidden';
- if(enetobjTimer) window.clearInterval(enetobjTimer)
- }
- </SCRIPT>
- <DIV id=enetMeng
- style="BORDER-RIGHT: #455690 1px solid; BORDER-TOP: #a6b4cf 1px solid; Z-INDEX: 99999; LEFT: 0px; VISIBILITY: visible; BORDER-LEFT: #a6b4cf 1px solid; 1px solid; POSITION: absolute; TOP: -256px; HEIGHT: 157px">
- <a href="连接地址"><img src="图片地址" border="0"></img>
- </div>
复制代码
效果演示:
http://www.moyu.cn/text.htm
将代码放在JS中
http://www.moyu.cn/test2.js
下面是
一直浮在右下角的代码
- document.writeln("<div align="center">");
- document.writeln(" <div id="ShowAD" style="position:absolute; z-index: 100;"> ");
- document.writeln(" <div id="ImgLayer" style="position:absolute; z-index:1; left: 0px;"> ");
- document.writeln(" <a href="http://union.kingsoft.com/union/download/index.html?uid=^^" target="_blank"><img src="http://www.moyu.cn/duba.gif" width="256" height="159" border="0"></a>");
- document.writeln(" </div>");
- document.writeln("</div>");
- document.writeln("</div>");
- ShowAD.style.top=document.body.clientHeight-159;
- ShowAD.style.left=document.body.clientWidth-256;
- moveR();
- function moveR() {
- ShowAD.style.top=document.body.scrollTop+document.body.clientHeight-159;
- ShowAD.style.left=document.body.scrollLeft+document.body.clientWidth-256;
- setTimeout("moveR();",80)
- }
复制代码
效果演示
http://www.moyu.cn/text2.htm
不一定 用做 毒霸联盟 也可以 为自己的新站做 AD ![](static/image/smiley/default/biggrin.gif)
欢迎提供素材 定制 消息框 ~~ FREE
![](http://www.moyu.cn/qq3.gif)
这图可以配合 弹出代码 弹到屏幕中间 诱导 易趣 淘宝之类 效果的话 我不知道 应该是不太好的 ![](static/image/smiley/default/lol.gif)
还好这次有准备 把文章复制到 写字扳里先 刚刚标题字又太多了 超过了80个字符
上次就是这么没了一精华 ![](static/image/smiley/default/lol.gif) ![](static/image/smiley/default/lol.gif)
[ Last edited by moyu on 2005-7-22 at 15:51 ] |
|