<% Set fso = CreateObject("Scripting.FileSystemObject") '建立對象的實例 Set f = fso.OpenTextFile(Server.MapPath("count.no"), 1, True) '建立文本文件,打開為只讀. if f.AtEndOfStream then '判斷這個文件是否不存在 no=1 else no=f.ReadLine no=no+1 end if f.Close set f=fso.OpenTextFile(Server.MapPath("count.no"),2,True) '準備寫 f.Write(no) '寫入 f.Close '改進標志1 no=CStr(no) '整齊數字 for i=1 to 5-len(no) no="0"&no next %> <font color=white size=3pt>你是第<font color=red><%=no%></font>個來客</font> |
溫馨提示:喜歡本站的話,請收藏一下本站!