//ed_ads广告配置文件开始

ed_ads_Price=6;


var caution = false
function setCookie(name, value, expires, path, domain, secure) {
        var curCookie = name + "=" + escape(value) +
                ((expires) ? "; expires=" + expires.toGMTString() : "") +
                ((path) ? "; path=" + path : "") +
                ((domain) ? "; domain=" + domain : "") +
                ((secure) ? "; secure" : "")
        if (!caution || (name + "=" + escape(value)).length <= 4000)
                document.cookie = curCookie
        else
                if (confirm("Cookie exceeds 4KB and will be cut!"))
                        document.cookie = curCookie
}
function getCookie(name) {
        var prefix = name + "="
        var cookieStartIndex = document.cookie.indexOf(prefix)
        if (cookieStartIndex == -1)
                return null
        var cookieEndIndex = document.cookie.indexOf(";", cookieStartIndex + prefix.length)
        if (cookieEndIndex == -1)
                cookieEndIndex = document.cookie.length
        return unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex))
}
function deleteCookie(name, path, domain) {
        if (getCookie(name)) {
                document.cookie = name + "=" +
                ((path) ? "; path=" + path : "") +
                ((domain) ? "; domain=" + domain : "") +
                "; expires=Thu, 01-Jan-70 00:00:01 GMT"
        }
}
function fixDate(date) {
        var base = new Date(0)
        var skew = base.getTime()
        if (skew > 0)
                date.setTime(date.getTime() - skew)
}
var now = new Date()
fixDate(now)
now.setTime(now.getTime() + 60 * 60 * 1000)
var ed__state__visits = getCookie("ed__state__ip_check_"+ed_ads_Price)
if (!ed__state__visits)
        ed__state__visits = 1
else
        ed__state__visits = parseInt(ed__state__visits) + 1
setCookie("ed__state__ip_check_"+ed_ads_Price, ed__state__visits, now)
setCookie("ed__state__test", now, now)
var ed__state__test = getCookie("ed__state__test")
if (ed__state__test!=now) ed__state__visits=0
//document.write(ed__state__visits)
//document.write(ed__state__test)

document.write('<div id="img" style="position:absolute; left: 27px; top: 1115px"><img src="http://images.28.com/ws/jinder/images/piaofu.gif" border=0 ></a></div>');
var xPos = 20;  
var yPos = document.body.clientHeight;  
var step = 1;  
var delay = 30;   
var height = 0;  
var Hoffset = 0;  
var Woffset = 0;  
var yon = 0;  
var xon = 0;  
var pause = true;  
var interval;  
img.style.top = yPos; 
function changePos() {  
width = document.body.clientWidth;  
height = document.body.clientHeight;  
Hoffset = img.offsetHeight;  
Woffset = img.offsetWidth;  
img.style.left = xPos + document.body.scrollLeft; 
 img.style.top = yPos + document.body.scrollTop;  
if (yon) {  yPos = yPos + step;  }  
else {  yPos = yPos - step;  }  
if (yPos < 0) {  yon = 1;  yPos = 0;  }  
if (yPos >= (height - Hoffset)) {  yon = 0;  yPos = (height - Hoffset);  }  
if (xon) {  xPos = xPos + step;  }  
else {  xPos = xPos - step;  }  
if (xPos < 0) {  xon = 1;  xPos = 0;  }  
if (xPos >= (width - Woffset)) {  xon = 0;  xPos = (width - Woffset);     }  
}  
function start() {  
img.visibility = "visible";  
interval = setInterval('changePos()', delay);  
}  
start();

//ed_ads广告配置文件结束

