mirror of
https://github.com/rsyslog/loganalyzer.git
synced 2025-09-26 03:09:21 +02:00
Added Maximize/Normalize button into the menu.
Using this button, you can show and hide and header in your session to maximize useability of phpLogCon.
This commit is contained in:
parent
41e406d8b5
commit
5fd875c0ce
@ -440,6 +440,8 @@ function InitFrontEndVariables()
|
||||
$content['MENU_SOURCE_DISK'] = $content['BASEPATH'] . "images/icons/document_text.png";
|
||||
$content['MENU_SOURCE_DB'] = $content['BASEPATH'] . "images/icons/data_table.png";
|
||||
$content['MENU_SOURCE_PDO'] = $content['BASEPATH'] . "images/icons/data_gear.png";
|
||||
$content['MENU_MAXIMIZE'] = $content['BASEPATH'] . "images/icons/table_selection_all.png";
|
||||
$content['MENU_NORMAL'] = $content['BASEPATH'] . "images/icons/table_selection_block.png";
|
||||
|
||||
$content['MENU_PAGER_BEGIN'] = $content['BASEPATH'] . "images/icons/media_beginning.png";
|
||||
$content['MENU_PAGER_PREVIOUS'] = $content['BASEPATH'] . "images/icons/media_rewind.png";
|
||||
|
@ -41,12 +41,28 @@ if ( !defined('IN_PHPLOGCON') )
|
||||
|
||||
function InitFrontEndDefaults()
|
||||
{
|
||||
global $content;
|
||||
|
||||
// To create the current URL
|
||||
CreateCurrentUrl();
|
||||
|
||||
// --- BEGIN Main Info Area
|
||||
|
||||
|
||||
$content['MAXURL'] = $content['BASEPATH'] . "userchange.php?";
|
||||
if ( isset($_SESSION['SESSION_MAXIMIZED']) && $_SESSION['SESSION_MAXIMIZED'] == true )
|
||||
{
|
||||
$content['MAXIMIZED'] = true;
|
||||
$content['MAXIMAGE'] = $content['MENU_NORMAL'];
|
||||
$content['MAXLANGTEXT'] = $content['LN_MENU_NORMALVIEW'];
|
||||
$content['MAXURL'] .= "op=maximize&max=0";
|
||||
}
|
||||
else
|
||||
{
|
||||
$content['MAXIMIZED'] = false;
|
||||
$content['MAXIMAGE'] = $content['MENU_MAXIMIZE'];
|
||||
$content['MAXLANGTEXT'] = $content['LN_MENU_MAXVIEW'];
|
||||
$content['MAXURL'] .= "op=maximize&max=1";
|
||||
}
|
||||
|
||||
// --- END Main Info Area
|
||||
|
||||
@ -65,6 +81,40 @@ function InstallFileReminder()
|
||||
}
|
||||
}
|
||||
|
||||
function GetAdditionalUrl($skipParam, $appendParam = "")
|
||||
{
|
||||
global $content;
|
||||
//echo $content['additional_url_full'];
|
||||
if ( isset($content['additional_url_full']) && strlen($content['additional_url_full']) > 0 )
|
||||
{
|
||||
if ( strlen($skipParam) > 0 )
|
||||
{
|
||||
// remove parameters from string!
|
||||
$szReturn = preg_replace("#(&{$skipParam}=[\w]+)#is", '', $content['additional_url_full']);
|
||||
if ( strlen($szReturn) > 0 )
|
||||
{
|
||||
if ( strlen($appendParam) > 0 )
|
||||
return $szReturn . "&" . $appendParam;
|
||||
else
|
||||
return $szReturn;
|
||||
}
|
||||
else if ( strlen($appendParam) > 0 )
|
||||
return "?" . $appendParam;
|
||||
else
|
||||
return "";
|
||||
}
|
||||
else
|
||||
return $content['additional_url_full'];
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( strlen($appendParam) > 0 )
|
||||
return "?" . $appendParam;
|
||||
else
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
function CreateCurrentUrl()
|
||||
{
|
||||
global $content, $CFG;
|
||||
@ -72,6 +122,7 @@ function CreateCurrentUrl()
|
||||
|
||||
// Init additional_url helper variable
|
||||
$content['additional_url'] = "";
|
||||
$content['additional_url_full'] = "";
|
||||
$content['additional_url_uidonly'] = "";
|
||||
$content['additional_url_sortingonly'] = "";
|
||||
$content['additional_url_sourceonly'] = "";
|
||||
@ -143,6 +194,9 @@ function CreateCurrentUrl()
|
||||
}
|
||||
else
|
||||
$content['additional_url'] .= "&" . $tmpvars[0] . "=" . $tmpvars[1];
|
||||
|
||||
// always append to this URL!
|
||||
$content['additional_url_full'] .= "&" . $tmpvars[0] . "=" . $tmpvars[1];
|
||||
}
|
||||
|
||||
$hvCounter++;
|
||||
|
@ -69,6 +69,9 @@ $content['LN_MENU_LOGIN'] = "Login";
|
||||
$content['LN_MENU_ADMINCENTER'] = "Admin Center";
|
||||
$content['LN_MENU_LOGOFF'] = "Logoff";
|
||||
$content['LN_MENU_LOGGEDINAS'] = "Logged in as";
|
||||
$content['LN_MENU_MAXVIEW'] = "Maximize View";
|
||||
$content['LN_MENU_NORMALVIEW'] = "Normalize View";
|
||||
|
||||
|
||||
// Index Site
|
||||
$content['LN_ERROR_INSTALLFILEREMINDER'] = "Warnung! Du hast das Installationsscript 'install.php' noch nicht aus dem phpLogCon Hauptordner entfernt!";
|
||||
|
@ -70,6 +70,8 @@ $content['LN_GEN_DB_SQLITE'] = "SQLite 2";
|
||||
$content['LN_MENU_ADMINCENTER'] = "Admin Center";
|
||||
$content['LN_MENU_LOGOFF'] = "Logoff";
|
||||
$content['LN_MENU_LOGGEDINAS'] = "Logged in as";
|
||||
$content['LN_MENU_MAXVIEW'] = "Maximize View";
|
||||
$content['LN_MENU_NORMALVIEW'] = "Normalize View";
|
||||
|
||||
// Main Index Site
|
||||
$content['LN_ERROR_INSTALLFILEREMINDER'] = "Warning! You still have NOT removed the 'install.php' from your phpLogCon main directory!";
|
||||
|
@ -73,6 +73,8 @@ $content['LN_GEN_SELECTVIEW'] = "Visão";
|
||||
$content['LN_MENU_ADMINCENTER'] = "Admin Center";
|
||||
$content['LN_MENU_LOGOFF'] = "Logoff";
|
||||
$content['LN_MENU_LOGGEDINAS'] = "Logged in as";
|
||||
$content['LN_MENU_MAXVIEW'] = "Maximize View";
|
||||
$content['LN_MENU_NORMALVIEW'] = "Normalize View";
|
||||
|
||||
// Main Index Site
|
||||
$content['LN_ERROR_INSTALLFILEREMINDER'] = "Atenção! Você ainda NÃO removeu o arquivo 'install.php' do diretório de seu phpLogCon!";
|
||||
|
@ -1,4 +1,3 @@
|
||||
<br><br>
|
||||
|
||||
<table width="100%" border="0" cellspacing="1" cellpadding="0" class="mainfooter">
|
||||
<tr>
|
||||
|
@ -11,6 +11,7 @@
|
||||
</head>
|
||||
<body TOPMARGIN="0" LEFTMARGIN="0" MARGINWIDTH="0" MARGINHEIGHT="0">
|
||||
|
||||
<!-- IF MAXIMIZED!="true" -->
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="mainheader">
|
||||
<tr>
|
||||
<td rowspan="4" width="500" align="left" valign="top"><a href="{BASEPATH}index.php"><img src="{BASEPATH}images/main/Header-Logo.png" width="500" height="79" name="HeaderLogo"></a></td>
|
||||
@ -65,7 +66,6 @@
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td width="100%" align="center" valign="top" height="20">
|
||||
|
||||
@ -116,7 +116,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<!-- ENDIF MAXIMIZED!="true" -->
|
||||
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="table_with_border">
|
||||
<tr>
|
||||
|
@ -23,5 +23,11 @@
|
||||
<!-- IF UserDBEnabled!="true" -->
|
||||
<td class="topmenuend" nowrap align="center" width="max"> </td>
|
||||
<!-- ENDIF UserDBEnabled!="true" -->
|
||||
|
||||
<!-- IF IS_NOLOGINPAGE!="true" -->
|
||||
<td class="topmenuextra" nowrap align="center" width="16">
|
||||
<a class="topmenu1_link" href="{MAXURL}" target="_top"><img align="left" src="{MAXIMAGE}" width="16" height="16" vspace="0" alt="{MAXLANGTEXT}" title="{MAXLANGTEXT}"></a>
|
||||
</td>
|
||||
<!-- ENDIF IS_NOLOGINPAGE!="true" -->
|
||||
</tr>
|
||||
</table>
|
||||
|
@ -236,6 +236,14 @@ font
|
||||
color: #FFFFFF;
|
||||
background-color: #290604;
|
||||
}
|
||||
.topmenuextra
|
||||
{
|
||||
height: 16px;
|
||||
font: 10px Verdana, Arial, Helvetica, sans-serif;
|
||||
color: #FFFFFF;
|
||||
background-color: #053841;
|
||||
}
|
||||
|
||||
.topmenu2begin
|
||||
{
|
||||
height: 20px;
|
||||
|
@ -239,6 +239,13 @@ font
|
||||
color: #FFFFFF;
|
||||
background-color: #597196;
|
||||
}
|
||||
.topmenuextra
|
||||
{
|
||||
height: 20px;
|
||||
font: 10px Verdana, Arial, Helvetica, sans-serif;
|
||||
color: #FFFFFF;
|
||||
background-color: #B8D4E0;
|
||||
}
|
||||
.topmenu2begin
|
||||
{
|
||||
height: 20px;
|
||||
|
@ -80,8 +80,17 @@ if ( isset($_GET['op']) )
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ( $_GET['op'] == "maximize" && isset($_GET['max']) )
|
||||
{
|
||||
if ( intval($_GET['max']) == 1 )
|
||||
{
|
||||
$_SESSION['SESSION_MAXIMIZED'] = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
$_SESSION['SESSION_MAXIMIZED'] = false;
|
||||
}
|
||||
}
|
||||
if ( $_GET['op'] == "changepagesize" && isset($_GET['pagesizeid']) )
|
||||
{
|
||||
if ( intval($_GET['pagesizeid']) >= 0 && intval($_GET['pagesizeid']) < count($content['pagesizes']) )
|
||||
|
Loading…
x
Reference in New Issue
Block a user