How do I destroy the zfcuser session variable manually within ZF2?

280 views Asked by At

Does anyone know how to destroy the Zfcuser session variable?

If certain events occur I would like to end the session?

I checked the wiki and the only discussion is about setting automatic timeout. I would like to destroy the session manually.

1

There are 1 answers

0
Rob M. On

If you are going for a general logout function session_destroy(); should suffice, otherwise just use unset($_SESSION['zfcuser']);