Home |  Chatroom  |  Members List |  Beer Funds  |  Drinking Schedule  |  Beer Facts   |  Jokes  |  WebMail  |  Forum  |  Contact Us

Drop your

Donations

Here!


 
 © Copyright Tatsk1 2005
Copyright DNet-US, South Carolina
<% Dim theNum Dim theFile Dim initCTR Dim objFSO set objFSO = Server.CreateObject("Scripting.FilesystemObject") set theFile = objFSO.GetFile(Server.MapPath("/counter.txt")) set initCTR = thefile.openastextstream(1) if isempty(session("Counter")) then theNum = initCTR.ReadAll() oldNum = theNum Session("Counter") = theNum theNum = theNum + 1 set initCTR = thefile.openastextstream(2) initCTR.write(theNum) theNum = formatNumber(theNum,6) Response.Write("[ " & thenum & " ]") else theNum = initCTR.ReadAll() oldNum = theNum Session("Counter") = theNum theNum = theNum + 1 set initCTR = thefile.openastextstream(2) initCTR.write(theNum) theNum = formatNumber(theNum,6) Response.Write("[ " & thenum & " ]") end if Function formatNumber(varNumber, intNumberSize) varNumber=CStr(varNumber) formatNumber=String(intNumberSize-Len(varNumber),"0") & varNumber End Function %>