inaba Posted May 26, 2008 Share Posted May 26, 2008 hi all In php how can i keep track that which of the users are viewing a certain page. Plz help if anybody knows. Quote Link to comment Share on other sites More sharing options...
PC Nerd Posted May 26, 2008 Share Posted May 26, 2008 if your looking for somethign similar to whats found here at php freaks - this is how I would go about it. at hte top of every page i woudl log when a user requests a page. eg - this topic, home page etc etc/ then when im trying to find out who is veiwing the page - you woudl loop through users online, on the current board, and then just check to see the most recent page request. if its the same page as the current one - then add it to an array and display that array or somthing similar. Alternative. every page request, add a record in a database for page requests. when a page is requested by a user, overwrite the users last requested page. then, on every page request, over write the time and page values. then all you have to do is search by page name, and order alpha or similar by the username. gdlk/. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.