Link to home
Start Free TrialLog in
Avatar of amara_78456
amara_78456

asked on

Counter in PHP

How can we create the counter in PHP for counting the number of people who conneted to my server ?
Avatar of calumscott
calumscott

The best way is probably to use a database to keep track of the number of people.  Simply keep a value in a database and increment it from your start page.

Use a database query to get the value back out of the DB and display it in whatever format you require.

If you need any help with this get back to me.
Another way if you do not want to use a database is to to use a function that every time your page is loaded will write to a file. This file has the current count and will increment it everytime the page is opened. If you need a code for that please reply to that message.
ASKER CERTIFIED SOLUTION
Avatar of heddesheimer
heddesheimer

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of amara_78456

ASKER

Thank you
Thank you
Force Accepted

SpideyMod
Community Support Moderator @Experts Exchange