gple Posted August 25, 2007 Share Posted August 25, 2007 I am developing a shopping cart and I just want to know how I would define two or more distinct sessions at the same time. Ie if one user comes in, how do I define one session with one name and another session with another name. Link to comment https://forums.phpfreaks.com/topic/66681-session/ Share on other sites More sharing options...
wildteen88 Posted August 25, 2007 Share Posted August 25, 2007 sessions are separate from users. sessions are not shared through users connected to the site. Every time someone connects to your site they get assigned a unique session id. Link to comment https://forums.phpfreaks.com/topic/66681-session/#findComment-334084 Share on other sites More sharing options...
Fadion Posted August 25, 2007 Share Posted August 25, 2007 Im guessing u need smth like this: //if user logins correctly session_start(); $_SESSION['username'] = 'John Smith'; $_SESSIoN['type'] = 'moderator'; U can create even 10 session variables for one user this way. But maybe this wasnt what u were asking. Link to comment https://forums.phpfreaks.com/topic/66681-session/#findComment-334110 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.