Re: Sessions that last for ever

From: Date: Sat, 16 Feb 2002 23:55:32 +0000
Subject: Re: Sessions that last for ever
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-85070@lists.php.net to get a copy of this message
> But very many commercial sites, including Apple and Amazon to name two, > do exactly this. When you re-enter the site they 'remember' who you are > using a cookie. In my case, I'm building a multi-player strategy game > and while I want the players to go through an initial briefing the first > time they ever join the game, thereafter they should be able to get > straight into the game if they are still using the same PC. But as I > said, the specifics of my use aren't so important - lots of sites leave > permanent cookies around and the results don't seem to be catastrophic. > > The question is still: how to do it? If each user has a unique user id, then make a table called seen_briefing: create table seen_briefing ( id int(11) unsigned not null default '0', primary key (id) ) Make an entry once a user has seen whatever they need to. Then, on their next login, do a join against the seen_briefing table, check for an entry... -- Greg Donald

« previous php.general (#85070) next »