}
/* Load Ajax interface. */
-$logout_link = Horde::getServiceLink('logout', 'kronolith');
-if ($logout_link) {
- $logout_link = Horde::widget($logout_link, _("_Logout"), 'logout');
-}
$help_link = Horde::getServiceLink('help', 'kronolith');
if ($help_link) {
$help_link = Horde::widget($help_link, _("Help"), 'helplink', 'help', Horde::popupJs($help_link, array('urlencode' => true)) . 'return false;');
msgs.find(function(m) {
switch (m.type) {
case 'horde.ajaxtimeout':
- this.logout(Kronolith.conf.timeout_url);
+ this.logout(m.message);
return true;
case 'horde.alarm':
}, this);
},
- logout: function(url)
+ logout: function()
{
this.is_logout = true;
- this.redirect(url || (Kronolith.conf.URI_IMP + '/LogOut'));
+ this.redirect(Kronolith.conf.URI_AJAX + 'LogOut');
},
redirect: function(url)
e.stop();
return;
+ case 'kronolithLogout':
+ this.logout();
+ e.stop();
+ return;
+
case 'kronolithMinicalDate':
this.go('month:' + orig.retrieve('date'));
e.stop();
<?php endif; ?>
<a href="#" id="kronolithNotifications" class="kronolithNotifications" title="<?php echo ("0 notifications") ?>"></a>
<span class="kronolithSeparator">|</span>
- <a href="#" id="kronolithOptions"><?php echo _("Options") ?></a><?php if ($help_link) echo ' <span class="kronolithSeparator">|</span> ' . $help_link; if ($logout_link) echo ' <span class="kronolithSeparator">|</span> ' . $logout_link ?>
+ <a href="#" id="kronolithOptions"><?php echo _("Options") ?></a><?php if ($help_link) echo ' <span class="kronolithSeparator">|</span> ' . $help_link; if (Horde_Menu::showService('logout')) { $ak = Horde::getAccessKey(_("_Logout")); echo ' <span class="kronolithSeparator">|</span> <a href="#" accesskey="' . $ak . '" id="kronolithLogout">' . Horde::highlightAccessKey(_("_Logout"), $ak) . '</a>'; } ?>
</div>
<!-- end services -->