Logout function for main menu

Martin List-Petersen martin@list-petersen.dk
Tue, 11 Dec 2001 08:51:25 +0100


---------------------- multipart/alternative attachment
$this->applications['logout'] =3D array( =20
    'fileroot' =3D> dirname(__FILE__) . '', =20
    'webroot' =3D> '/horde/login.php?reason=3Dlogout&',=20
    'icon' =3D> '/horde/graphics/logout.gif',
    'name' =3D> _("LogOut"), =20
    'allow_guests' =3D> false,
    'show' =3D> true
);

This (yes, it's quick and dirty) hack added in horde/config/registry.php =
(at any place amount the applications, depending on, where you want the =
logout menu) will give you the logout functionality.

Unfortunately i couldn't find any function to check if somebody is =
logged in or not, like available in IMP ( if (($reason =3D =
IMP::authenticate(null, true)) !=3D=3D true) ). This function the would =
make it possible to turn this menu off, if the user isn't logged in.

Regards,
Martin List-Petersen
martin@list-petersen.dk
http://www.marlow.dk


---------------------- multipart/alternative attachment--