Hello. First I’d like to say that I know my way around pretty good but I am not a veteran PHP programmer so talk to me like I’m stupid please :slight_smile:

Ok… I have a simple chat script set up that will only be used by a few people. I figured out how to truncate the chat when someone logs out, but I can’t figure out how to truncate only if ALL users log out. Can someone lead me in the right direction?

Thanks :-*

i’d do something like this:
have a column in my database that records if users are logged in or out (1 or 0)
then run a query:
$query = mysql_query(“SELECT * FROM database WHERE logged_in = 1”);
// 1 or more users are still logged in, do something
// everybody logged out, do something


Sponsor our Newsletter | Privacy Policy | Terms of Service