Theme: Fix js confirmation on logout icon click (set language variable as global inside menu function).

This commit is contained in:
reliberate 2016-03-27 03:22:42 -06:00
parent 5864777a64
commit 74a25f19c0
1 changed files with 3 additions and 5 deletions

View File

@ -1559,23 +1559,21 @@
</div>
<?php
}
?>
<?php
// qr code container for contacts
echo "<div id='qr_code_container' style='display: none;' onclick='$(this).fadeOut(400);'>";
echo " <table cellpadding='0' cellspacing='0' border='0' width='100%' height='100%'><tr><td align='center' valign='middle'>";
echo " <span id='qr_code' onclick=\"$('#qr_code_container').fadeOut(400);\"></span>";
echo " </td></tr></table>";
echo "</div>";
?>
<?php
if (!$default_login) {
//*************** BOOTSTRAP MENU ********************************
function show_menu($menu_array, $menu_style, $menu_position) {
global $text;
//determine menu behavior
switch ($menu_style) {
@ -1687,7 +1685,7 @@
//logout icon
if ($_SESSION['username'] != '' && $_SESSION['theme']['logout_icon_visible']['text'] == "true") {
$username_full = $_SESSION['username'].((count($_SESSION['domains']) > 1) ? "@".$_SESSION["user_context"] : null);
echo "<li class='hidden-xs'><a href='".PROJECT_PATH."/logout.php' onclick=\"return confirm('".$text['theme-confirm-logout']."')\"><span class='glyphicon glyphicon-log-out'></span></a></li>";
echo "<li class='hidden-xs'><a href='".PROJECT_PATH."/logout.php' title=\"".$text['theme-label-logout']."\" onclick=\"return confirm('".$text['theme-confirm-logout']."')\"><span class='glyphicon glyphicon-log-out'></span></a></li>";
unset($username_full);
}
?>