Hit Counter Example

0 views
Skip to first unread message

hoboro

unread,
Mar 28, 2008, 5:24:44 PM3/28/08
to TurboGears
Anyone out there can point me out to an example or code that has a
counter Hit. I want to see people
hitting my website.


Thank You
Rohan

percious

unread,
Mar 28, 2008, 5:38:39 PM3/28/08
to TurboGears
That is so web 1.0.
:-P
seriously though, it would make a nice widget. Please make a TW for
it and publish it.

How are you planning on storing the hits? In the database via orm?
In a file?

-chris

midtoad

unread,
Mar 29, 2008, 1:09:33 AM3/29/08
to TurboGears
Here's a pretty simple-minded example: http://paste.turbogears.org/paste/2360

Read the counter out of a text file each time you load the page,
increment it, write it back to the file.

In your welcome.kid, insert a line like this:
<p>You are visitor no. ${count}.</p>


On Mar 28, 3:24 pm, hoboro <rohan...@gmail.com> wrote:
Reply all
Reply to author
Forward
0 new messages