悬赏园豆:10
[已关闭问题]
我寫了一個Cookie用來測試客戶端的訪問記錄,但是有一個小問題,統計數據不能變化,請幫忙看看是什麽問題,謝謝!<br>
<div class="cnblogs_code"><%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%><br><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><br><html xmlns="http://www.w3.org/1999/xhtml"><br><head><br><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><br><title>上次訪問時間</title><br></head><br><%<br> dim LastVisit<br> dim VisitCount<br> LastVisit=request.Cookies("LastVisitCookie")<br> response.Cookies("LastVisitCookie")=FormatDatetime(now())<br> response.Cookies("LastVisitCookie").expires=date()+30<br> VisitCount=request.Cookies("VisitCount")<br> if VisitCount > "0" then<br> VisitCount=VisitCount+1<br> else<br> VisitCount=1<br> end if<br> response.Cookies("VisisCount")=VisitCount<br> response.Cookies("VisitCount").expires=date()+30 <br>%><br><body><br><p>使用Cookies</p><br> <hr /><br> <%<br> if LastVisit="" then<br> response.Write("歡迎光臨本站")<br> else<br> response.Write "你上一次訪問本頁在" & LastVisit & "<br>"<br> response.Write "你這是第<font size='8' color='ccbbaa'> " & VisitCount & "</font>次訪問本頁"<br> end if <br> %><br><p><a href="CookiesDemo.asp">重新訪問本頁</a></p> <br></body><br></html><br><span id="Code_Closed_Text_142615" class="cnblogs_code_Collapse"></span></div>