Hi all,
How to know how many users are online to a particular website?
Thanks
Loading
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend4days leftRegister
Zoran HorvatRank #792 · 2.9K reputationPosted Nov 21, 2010, 9:59 AM EST
Satyapriya NayakRank #47 · 31.5K reputationPosted Nov 21, 2010, 6:29 PM EST
To any website it means,suppose in http://www.c-sharpcorner.com/ homepage it is seems to be Total Online Users:
thanks
Zoran HorvatRank #792 · 2.9K reputationPosted Nov 22, 2010, 11:37 PM EST
So each particular user is considered online all until cookie times out (looked from the client perspective) or until session object is removed from collection of live sessions (looked from the server perspective). This, however doesn't mean that this user is really online. He might have shut down the computer as well, and be considered online for couple of minutes or couple of hours more, falsely.
To conclude, counting online users typically boils down to a tradeoff of counting active sessions, hoping that it will not be too far away from the truth.
If you have administrative access to Web server (IIS, Apache...), then there are means to dig data out of it. For example, ASP.NET maintains performance counters giving own state, among other - giving number of active sessions. PHP maintains sessions on disk and some counting can be done on appropriate location (I'm not too familiar with this). And so on, there are general ways of getting this information when you're administrator.