这个是一个二十四小时只弹一次的弹窗代码,用来在论坛宣传cuhome。
代码加在广告设置——页尾广告
代码内容:
<script language="JavaScript">
<!--
function setCookie(name, value, expire) {
window.document.cookie = name + "=" + escape(value) + ((expire == null) ? "" : ("; expires=" + expire.toGMTString()));
}
function getCookie(Name) {
var search = Name + "=";
if (window.document.cookie.length > 0) { // if there are any cookies
offset = window.document.cookie.indexOf(search);
if (offset != -1) { // if cookie exists
offset += search.length; // set index of beginning of value
end = window.document.cookie.indexOf(";", offset) // set index of end of cookie value
if (end == -1)
end = window.document.cookie.length;
return unescape(window.document.cookie.substring(offset, end));
}
}
return null;
}
function register(name) {
var today = new Date();
var expires = new Date();
expires.setTime(today.getTime() + 1000*60*60*24);
setCookie("SexMovie", name, expires);
}
var exitURL="http://www.hongchen2006.com/uchome/index.php";
function openWin() {
var c = getCookie("SexMovie");
if (c != null) {
return;
}
register("9free");
var featureStr="''";
featureStr="'top=0,left=0,width=600,height=400,toolbar=yes, menubar=yes, scrollbars=yes, resizable=yes, location=yes, status=yes,center:yes'";
self.focus();
var ExitWindow = window.open(exitURL,'', featureStr);
//ExitWindow.focus();
}
openWin();
//window.focus()
-->
</script>
请将网址部份,换成你想弹的页页。
另外,我想请大家帮忙,是请在家帮忙教我怎么调用个人空间,到论坛首页,我按照论坛上给的方法都试过了,头像是导出来了,可链接地址打不开。
有什么绝对好的方法吗?随便调空间,调日志都行,谢谢。
弹窗效果见我的网址地址:
http://www.hongchen2006.com/bbs |