suspendcode="<DIV id=lovexin1 style='Z-INDEX: 10; LEFT: 3px; POSITION: absolute; TOP: 130px; width:30px; height: 250px;'><img src='http://www.huajiemba.com/2010/ad/close.gif' onClick='javascript:window.hide()' width='30px' height='14px' border='0' vspace='3' alt='关闭对联广告'><a href='http://gz.huajiemba.com/HTML/27268.html' target='_blank'><img src='http://www.huajiemba.com/2010/ad/left_ad_gz.gif' alt='华杰最新讲义答案下载专区' width='30px' height='200px' border='0'></a></DIV>"
document.write(suspendcode);

suspendcode2="<DIV id=lovexin2 style='Z-INDEX: 10; right: 2px; POSITION: absolute; TOP: 130px; width: 30px; height: 250px;'><img src='http://www.huajiemba.com/2010/ad/close.gif' onClick='javascript:window.hide()' width='30px' height='14px' border='0' vspace='3' alt='关闭对联广告'><a href='http://gz.huajiemba.com/HTML/27268.html' target='_blank'><img src='http://www.huajiemba.com/2010/ad/right_ad_gz.gif' width='30px' height='200px' border='0'></a></DIV>"
document.write(suspendcode2);

//flash格式调用方法
//<EMBED src='flash.swf' quality=high  WIDTH=100 HEIGHT=300 TYPE='application/x-shockwave-flash' id=ad wmode=opaque></EMBED>

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("lovexin1").style.top=parseInt(document.getElementById("lovexin1").style.top)+percent+"px";
document.getElementById("lovexin2").style.top=parseInt(document.getElementById("lovexin2").style.top)+percent+"px";

lastScrollY=lastScrollY+percent; 
//alert(lastScrollY);
}
function hide()  
{   
lovexin1.style.visibility="hidden"; 
lovexin2.style.visibility="hidden";
}
window.setInterval("heartBeat()",1);
