<!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>符合标准的正常工作的对联广告</title>
<script language="JavaScript" type="text/javascript">
lastScrollY=0;
function heartBeat(){
var diffY;
if (document.documentElement && document.documentElement.scrollTop)
diffY = document.documentElement.scrollTop;
else if (document.body)
diffY = document.body.scrollTop
else
{/*Netscape stuff*/}
//alert(diffY);
percent=.1*(diffY-lastScrollY);
if(percent>0)percent=Math.ceil(percent);
else percent=Math.floor(percent);
document.getElementById("lovexin12").style.top=parseInt(document.getElementById
("lovexin12").style.top)+percent+"px";
document.getElementById("lovexin14").style.top=parseInt(document.getElementById
("lovexin12").style.top)+percent+"px";
lastScrollY=lastScrollY+percent;
//alert(lastScrollY);
}//from webjx.com
suspendcode12="<DIV id=\"lovexin12\" style='left:2px;POSITION:absolute;TOP:120px;'>ad1</div>"
suspendcode14="<DIV id=\"lovexin14\" style='right:2px;POSITION:absolute;TOP:120px;'>ad2</div>"
document.write(suspendcode12);
document.write(suspendcode14);
window.setInterval("heartBeat()",1);
</script>
<style type="text/css">
<!--
#lovexin12,#lovexin14{
width:120px;
height:250px;
background-color:#e5e5e5;
border:1px solid #ddd;
}
html,body{
height:1000px;
}
#mm{
height:1000px;
}
-->
</style>
</head>
<body>
<div id="mm">
</div>
</body>
</html>
分享到:
相关推荐
纯JS两侧浮动对联广告及判断客户端分辩率, 可自定义两侧浮动对联广告位置、判断客户端分辩率等显示,可分别关闭两侧浮动对联广告。本js广告代码兼容浏览器IE6、IE7、IE8、IE9、firefox、chrome、opera、safari, js...
jquery浮动图片广告代码_页面上漂浮图片广告代码 jquery浮动图片广告代码_页面上漂浮图片广告代码
jQuery浮动图片广告代码简介: jQuery浮动图片广告代码是一款页面上漂浮图片广告代码。
浮动图片广告代码是一款页面上漂浮图片广告代码。
jQuery侧面浮动对联广告
js浮动广告代码,四周漂浮的广告代码,用起来很方便。
一个浮动广告的html代码,有助于网站建设,广告联盟,网络赚钱,等等
网页两侧浮动广告代码,亲测可用
网页两侧的浮动对联广告,随鼠标滑动,压缩包内有两个对联广告,分别是有关闭按钮和无关闭按钮。
简洁易用的jQuery左右对称浮动广告代码是一个非常简单好用的jQuery对联广告代码,直接引入jQuery插件,本插件,然后再来一个调用方法即可,简单易用,不会出现冲突
javascript浮动广告代码
浮动广告代码,浮动广告代码,浮动广告代码
广告浮动广告,对联广告,图片广告。图片广告可以多个
jQuery插件,就是沿着一个角度弹来弹去的,代码写得不怎么样,不过效果达到了,调用很简单的,里面有调用例子。ie6/ie7/ie8/firefox下都能用
浮动广告的代码 浮动广告的代码 浮动广告的代码
浮动广告代码 右下角漂浮代码 [removed] initAd();//载入页面后,调用函数initAd() [removed] [removed] <!-- function initAd() { document.all.AdLayer.style.posTop = -200; //设置onLoad事件激发以后,广告层...
实现漂浮广告,点击图片可以跳转到广告页面,点击关闭可以关闭广告
网页浮动广告代码 非常好的 网页浮动广告代码 非常好的 网页浮动广告代码 非常好的
js浮动广告代码,常见的在屏幕内漂浮的图片广告效果,可以吸引用户注意力,缺点是用户体验稍差 网页两侧浮动广告代码 网页固定位置浮动图片广告代码