tags:

views:

57

answers:

2

Possible Duplicate:
Is this a proper way to destroy all sessions in php?

Hey Guys,

what's the best way to destroy all sessions (not just the one of the current user).

Thanks in advance!

+2  A: 

It depends on how your sessions are being stored. If they're in a database, just delete them. If they're on the file system somewhere like in /tmp, just delete them. For information on sessions in PHP, check out the manual. http://www.php.net/manual/en/book.session.php

Timothy
A: 

Sometimes this function help me: session_destroy();

Alexander.Plutov
Only destroys the current session. The OP needs a way to get rid of all sessions, or at least sessions besides the current one.
cHao
I said, that this SOMETIMES helps me.
Alexander.Plutov