Copy Code code as follows:
<script language= "JavaScript" >
<!--
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 would 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 () + 365 * 24 * 60 * 60 * 1000)
var visits = GetCookie ("Counter")
if (!visits)
Visits = 1
Else
visits = parseint (visits) + 1
Setcookie ("Counter", visits, now)
document.write ("You are visiting the first" + Visits + "User!" ")
-->
</script>