I have noticed, that most most people instead of logging out just close the tab or browser. The result of thsi si taht they stay logged in until teh forum says they're inactive. I was just wondering whether there was something you could do to stop this, e.g. automatically log out when firefox is closed.
Again, i know nothing about forum code and don't know whether I'm barking up the wrong tree or what it just really annoys me.
I honestly don't really see the big deal of this, or what the problem is.
It doesn't bother me at all, but I'm one of those who does that, so there you go.
Also, I guess I can tell when someone isn't at the site anymore through the time stamp on the Who's Online page.
But anyway.. the reason it's like that is because of the cookie function of the browser. They don't like logging off/back on every time. Just like me.
I doubt it's possible to create code like that, though. But what do I know, I'm not a programmer. =P
Changing the forum so that it logs you out when you close your browser defeats the purpose of keeping a member logged in to begin with. If the 15 minute "online" cooldown time after a person stops browsing pages is too intense for you, I could always shorten the time to 5 minutes instead. Keep in mind, if someone were to idle on a page for, say, 20 minutes to type a really long post, the forum would note that the member is no longer online because there has been no activity in 15 minutes' time. As it is, I don't see this as an issue, so I don't have much incentive to change anything.
Community Manager; Forum Administrator
reppin' SOLDIER since 2004 • CPC8 class of 2009
Random;:
Originally Posted by 2009 TFF Awards nominations
Best TFF Couple
Martin and Priscilla
Psiko and Hyzenthlay Rocky and LocoColt04 and Meier Link and Pete
Unknown Entity and Mistress Sheena
Originally Posted by Andromeda
I thought I was going to be able to play with Loco and then I remembered he doesn't game. He just turns on the game for an hour and then forgets about it for two months only to remember that he bought it.
Originally Posted by Rowan
Che's not a girl. Not good enough explanation. Please elaborate.
The other two answers are technically correct, to a point, but not really. The forums have no means of knowing when the browser is closed or opened, as it runs on the server and not your computer. While there is possibly a way to capture a Browser_Closing DOM event through javascript, it wouldn't be a wise idea. I won't go into all the reasons why because it is way beyond the scope of the question, but needless to say, what you are asking for is not feasibly possible. The forums cannot log you in when you come and then log you out when you leave.
What you're asking for would involve directly accessing lower layers of the network protocol, which wouldn't exactly be safe. Hell, I don't think PHP even has access to that layer anyway. Only the server itself knows exactly when you stopped sending stuff to it, and that technically isn't an indication that you actually left. It would then log you out every time your browser finished loading. Obviously, that would suck, eh?
In the end, it's a lot different than running a program locally on your computer. Between computers they kinda just have to guess. It isn't exactly accurate, but it's the best they can do on the layer they have access to.
Bookmarks