[imp] Logout button idea

Patrick Boutilier boutilpj at ednet.ns.ca
Wed Mar 12 11:37:52 PST 2003


I am using Horde 2.2.1, IMP 3.2.1, Turba 1.2, and Passwd 2.2.1-cvs. My 
setup hides the /horde directory so apps are accessed like 
http://student.ednet.ns.ca/imp, http://student.ednet.ns.ca/turba , etc..

When I log out of IMP and log back in again I am in IMP. However when 
logging out of Turba and Passwd and then logging back in again I am 
brought into the Horde summary screen.

To fix the problem at my site I changed the part of the horde 
registry.php file from


$this->applications['logout'] = array(
     'fileroot' => dirname(__FILE__) . '/..',
     'webroot' => $this->applications['horde']['webroot'],
     'initial_page' => 'login.php?reason=logout',
     'icon' => $this->applications['horde']['webroot'] . 
'/graphics/logout.gif',
     'name' => _("Logout"),
     'allow_guests' => false,
     'status' => 'notoolbar'
);




to



$this->applications['logout'] = array(
     'fileroot' => dirname(__FILE__) . '/..',
     'webroot' => $this->applications['horde']['webroot'] . '/imp',
     'initial_page' => 'login.php?reason=logout',
     'icon' => $this->applications['horde']['webroot'] . 
'/graphics/logout.gif',
     'name' => _("Logout"),
     'allow_guests' => false,
     'status' => 'notoolbar'
);



and then added the Logout button to the menu using the 
$conf['menu']['apps'] configuration option in each app.


For example in IMP:


$conf['menu']['apps'] = array('turba','passwd','logout');



The final step is to remove the second Logout button that appears in 
apps that put there own Logout buttons in. It is usually in 
templates/menu/menu.inc

For example in IMP:

/* Logout */
//if ($registry->getMethod('auth/logout') == 'imp' && 
!$imp['direct_access']) {
//    Menu::printItem(Horde::url($registry->getParam('webroot', 'horde') 
. '/login.php?reason=logout'), _("Logout"), 'logout.gif', 
$registry->getParam('graphics', 'horde'));
//} else {
//    Menu::printItem(Horde::applicationUrl('login.php?reason=logout'), 
_("Logout"), 'logout.gif', $registry->getParam('graphics', 'horde'));
//}



More information about the imp mailing list