|
Description: | |
I want to have Text Hit Counter on my home page. | |
Solution: | |
Add the following code into your Home Page
.asp file at the position of your
choice. <% set fso = createobject("scripting.filesystemobject") set act = fso.opentextfile(server.mappath("counter.txt")) counter = clng(act.readline) counter = counter + 1 act.close Set act = fso.CreateTextFile(server.mappath("counter.txt"), true) act.writeline(counter) act.close counter_length = len(counter) Response.Write counter |
hostonjava | 4/27/2024 12:47:25 AM |