Wrox Programmer Forums
|
Beginning PHP Beginning-level PHP discussions. More advanced coders should post to the Pro PHP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning PHP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 16th, 2003, 03:04 PM
Authorized User
 
Join Date: Jun 2003
Posts: 83
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to natmaster Send a message via AIM to natmaster Send a message via MSN to natmaster
Default SESSION tracking

is there any way to track the sessions with each user? so like if i had a session variable called 'bob' then i could access the 'bob' session for every user that has that session variable...

----------------------------
Aeon of Darkness MUD - Free Online Roleplaying Game
http://aeonofdarkness.com
__________________
----------------------------
Aeon of Darkness MUD - Free Online Roleplaying Game
http://aeonofdarkness.com
 
Old August 18th, 2003, 01:52 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 836
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Uh, it really depends on how you're storing your session data. If you have custom session handlers that store session data in the database, you can simply query the session data table and search for the "bob" variable in all the active sessions.

Typically, session data is all serialized into a single string before it's stored in a database, then unserialized as it's extracted. You might want to modify the way this happens if you really need to track common variables across multiple user sessions. Perhaps your session table can store active key/value pairs for sessions. This will require additional insert/select queries for each session write/read, but that's the price you pay!

You can perform a similar search throuh all the temp session files if you're NOT using custom sessions, though I can't imagine why you'd want to do that.


Take care,

Nik
http://www.bigaction.org/





Similar Threads
Thread Thread Starter Forum Replies Last Post
Session Tracking Using SQLServer 2000 brojoonline General .NET 1 August 3rd, 2007 04:25 AM
Session tracking with google popup blocker dshamim Classic ASP Professional 0 December 20th, 2006 09:48 AM
Tracking who is changing what? rrhandle SQL Server 2000 1 August 15th, 2006 03:03 AM
UPS Tracking jafarsalam XML 0 October 20th, 2004 04:23 PM
Chap. 11 - Try It Out, Session Tracking with PHP Tachyon BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 5 June 17th, 2004 02:02 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.