Online user statistics in ASP.NET

xiaoxiao2021-03-06  117

The role of statistics online users is self-evident, which is to know how much the current user is, and then observe the performance of the server or program according to the number of users, so it can be intuitive to understand the attraction of the website or the efficiency of the website program. Now, we will introduce a simple and clear way to count how much online users. The characteristics of this method are to fully utilize the characteristics of ASP.NET, combined with the Global.asax file, using Application and Session to realize online users, Since only one Application is used in the program, the program occupies system resources can almost neglect, of course, this is also one of the most concerned issues of website managers. First, the user shows the use of the page First, let's take a look at how the number of access users of the current website, the program code is as follows: <% @ page language = "c #" debug = "true"%>