Jump to content

Java Hit Counter.


Vaelen2001

Recommended Posts

I'm making a website and need a java applet based hit counter that keeps track of the IP's that visit so it will only take into consideration one visit per IP address.

 

Unlike others that every time you refresh the page it counts as a hit...

 

If anyone can help me out with this i'd be much obliged.

 

--Vaelen2001

Share this post


Link to post
Share on other sites

  • 2 weeks later...

you can just use a web counter that goes by "unique hits" which just uses like one isp per hit so you cant just refresh and refresh.

Edited by Blinker

Share this post


Link to post
Share on other sites

I wrote a hit counter in ASP for my boss, you can use it just make sure you name your pages .asp :)

 

 

<%
on error resume next 

set fso = createobject("scripting.filesystemobject")
set act = fso.opentextfile(server.mappath("asp_count.txt"))
counter = clng(act.readline)

counter = counter + 1
act.close

Set act = fso.CreateTextFile(server.mappath("asp_count.txt"), true)
act.WriteLine(counter)
act.Close

Response.Write counter
%>

Share this post


Link to post
Share on other sites

the ASP one is nice, but your host should have very detailed logs. and if they dont, well what host do you have if they dont?

 

 

I wouldnt use java. I would use php if I had to.

But my sites are run off php scripts.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...