點整[訪客計時器]係個blog到?

2008-07-27 10:21 pm
點整[訪客計時器]係個blog到?呢樣野係咪自己整?定係自己down唔該教下我~

回答 (1)

2008-07-28 5:01 am
✔ 最佳答案
<p align="center"> </p>

<hr width="90%">
<div align="center"><center>

<table border="0">
<tr>
<td><font size="6"><script language="JavaScript">
/////////////
//
// Cookie Functions - Bill Dortch (21-Jan-96)
// The following functions are released to the
// public domain.
//
function GookieVal(offset) {
var endstr = document.cookie.indexOf (";", offset);
if (endstr == -1)
endstr = document.cookie.length;
return unescape(document.cookie.substring(offset, endstr));
}

function Gookie(name) {
var arg = name + "=";
var alen = arg.length;
var clen = document.cookie.length;
var i = 0;
while (i < clen) {
var j = i + alen;
if (document.cookie.substring(i, j) == arg)
return GookieVal (j);
i = document.cookie.indexOf(" ", i) + 1;
if (i == 0) break;
}
return null;
}

function Sookie(name, value) {
var argv = Sookie.arguments;
var argc = Sookie.arguments.length;
var expires = (argc > 2) ? argv[2] : null;
var path = (argc > 3) ? argv[3] : null;
var domain = (argc > 4) ? argv[4] : null;
var secure = (argc > 5) ? argv[5] : false;
document.cookie = name + "=" + escape (value) +
((expires == null) ? "" : ("; expires="
+ expires.toGMTString())) +
((path == null) ? "" : ("; path=" + path)) +
((domain == null) ? "" : ("; domain=" + domain)) +
((secure == true) ? "; secure" : "");
}

function Dookie(name) {
var exp = new Date();
exp.setTime (exp.getTime() - 1);
var cval = Gookie (name);
document.cookie = name + "=" + cval + "; expires="
+ exp.toGMTString();
}
//
// End of cookie functions
//////////
</script></font></td>
</tr>
<tr>
<td><font size="4"><script>
var expdate = new Date();
// 設定期限為一年後
expdate.setTime(expdate.getTime() + (24 * 60 * 60 * 1000 * 365));
if(!(visits = Gookie("3wave"))) {visits = 1;
Sookie("3wave", visits, expdate, "/", null, false);
document.write("這是您第 " + visits + " 次光臨本站!");}
else{
// 將到站次數累加一次
visits++;
Sookie("3wave", visits, expdate, "/", null, false);
document.write("這是您第 " + visits + " 次光臨本站!");
}
</script></font></td>
</tr>
</table>
</center></div>

<hr width="90%">

<p align="center"> </p>


收錄日期: 2021-04-14 19:27:53
原文連結 [永久失效]:
https://hk.answers.yahoo.com/question/index?qid=20080727000051KK01124

檢視 Wayback Machine 備份