From 50fc96f78cf659a8232f7dd9b45d7eb8bb95beaa Mon Sep 17 00:00:00 2001 From: Janusz Dobrowolski Date: Sat, 14 Mar 2015 16:05:36 +0100 Subject: [PATCH] Additional cleanups in standard themes. --- themes/aqua/renderer.php | 34 ++++++++++++++-------------------- themes/cool/renderer.php | 33 ++++++++++++++------------------- themes/default/renderer.php | 18 ++++++++---------- 3 files changed, 36 insertions(+), 49 deletions(-) diff --git a/themes/aqua/renderer.php b/themes/aqua/renderer.php index 40b7f7ea..5f3843b2 100644 --- a/themes/aqua/renderer.php +++ b/themes/aqua/renderer.php @@ -19,7 +19,7 @@ $img = $category == '' ? 'right.gif' : $category.'.png'; else $img = 'right.gif'; - return "  "; + return "  "; } function wa_header() @@ -36,7 +36,7 @@ { global $path_to_root, $help_base_url, $db_connections; echo "\n"; - echo ""; + echo "\n"; echo "
\n"; echo "\n"; @@ -49,7 +49,6 @@ { $applications = $_SESSION['App']->applications; $local_path_to_root = $path_to_root; - $sel_app = $_SESSION['sel_app']; echo "
"; echo "
"; @@ -57,14 +56,13 @@ { if ($_SESSION["wa_current_user"]->check_application_access($app)) { - $acc = access_string($app->name); - echo "" .$acc[0] . ""; - } + $acc = access_string($app->name); + echo "" .$acc[0] . ""; + } } echo "
"; - echo "
"; // top status bar $img = ""._(  "; @@ -89,17 +87,14 @@ echo "
"; elseif ($title && !$is_index) { - echo "
" + echo "
$title
" ."" ."
$title" .(user_hints() ? "" : '') ."
"; } - - } - function menu_footer($no_menu, $is_index) { global $version, $allow_demo_mode, $app_title, $power_url, @@ -107,7 +102,7 @@ include_once($path_to_root . "/includes/date_functions.inc"); echo "
\n"; // 'main_page' - if ($no_menu == false) // bottom status line + if ($no_menu == false) // bottom status line { if ($is_index) echo "\n"; @@ -118,7 +113,7 @@ $phelp = implode('; ', $Pagehelp); echo "\n"; $Ajax->addUpdate(true, 'hotkeyshelp', $phelp); - echo "'; + echo ""; } echo "
" . Today() . " | " . Now() . "".$phelp.'".$phelp."
\n"; } @@ -127,15 +122,15 @@ { echo "\n"; echo "\n"; - echo "\n"; + echo "\n"; echo "\n"; echo "\n"; - echo "\n"; + echo "\n"; echo "\n"; if ($allow_demo_mode==true) { echo "\n"; - //echo "\n"; + //echo "\n"; echo "\n"; } echo "

\n"; @@ -147,7 +142,6 @@ global $path_to_root; $selected_app = $waapp->get_selected_application(); - if (!$_SESSION["wa_current_user"]->check_application_access($selected_app)) return; @@ -214,6 +208,6 @@ echo ""; } echo ""; - } + } } ?> \ No newline at end of file diff --git a/themes/cool/renderer.php b/themes/cool/renderer.php index fcf9a8dc..ddb7dcdd 100644 --- a/themes/cool/renderer.php +++ b/themes/cool/renderer.php @@ -36,7 +36,7 @@ { global $path_to_root, $help_base_url, $db_connections; echo "\n"; - echo ""; + echo "\n"; echo "
\n"; echo "\n"; @@ -49,7 +49,6 @@ { $applications = $_SESSION['App']->applications; $local_path_to_root = $path_to_root; - $sel_app = $_SESSION['sel_app']; echo "
"; echo "
"; @@ -57,23 +56,22 @@ { if ($_SESSION["wa_current_user"]->check_application_access($app)) { - $acc = access_string($app->name); - echo "" .$acc[0] . ""; - } + $acc = access_string($app->name); + echo "" .$acc[0] . ""; + } } echo "
"; - echo "
"; // top status bar - $img = ""._(  "; - $himg = ""._(  "; + $img = ""._(  "; + $himg = ""._(  "; echo ""; echo ""; $indicator = "$path_to_root/themes/".user_theme(). "/images/ajax-loader.gif"; - echo ""; + echo ""; echo "
" . $db_connections[$_SESSION["wa_current_user"]->company]["name"] . " | " . $_SERVER['SERVER_NAME'] . " | " . $_SESSION["wa_current_user"]->name . "" . _("Preferences") . "   \n"; echo " " . _("Change password") . "   \n"; @@ -85,7 +83,6 @@ echo "
"; } echo "
"; - if ($no_menu) echo "
"; elseif ($title && !$is_index) @@ -96,17 +93,16 @@ ."" .""; } - } function menu_footer($no_menu, $is_index) { - global $version, $allow_demo_mode, $app_title, $power_url, + global $version, $allow_demo_mode, $app_title, $power_url, $power_by, $path_to_root, $Pagehelp, $Ajax; include_once($path_to_root . "/includes/date_functions.inc"); echo "\n"; // 'main_page' - if ($no_menu == false) // bottom status line + if ($no_menu == false) // bottom status line { if ($is_index) echo "\n"; @@ -126,10 +122,10 @@ { echo "
\n"; echo "\n"; - echo "\n"; + echo "\n"; echo "\n"; echo "\n"; - echo "\n"; + echo "\n"; echo "\n"; if ($allow_demo_mode==true) { @@ -212,7 +208,6 @@ echo ""; } echo ""; - } + } } - ?> \ No newline at end of file diff --git a/themes/default/renderer.php b/themes/default/renderer.php index 252dbfb8..438d87de 100644 --- a/themes/default/renderer.php +++ b/themes/default/renderer.php @@ -9,7 +9,6 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the License here . ***********************************************************************/ - class renderer { function get_icon($category) @@ -20,7 +19,7 @@ $img = $category == '' ? 'right.gif' : $category.'.png'; else $img = 'right.gif'; - return "  "; + return "  "; } function wa_header() @@ -65,14 +64,14 @@ } echo ""; echo ""; - // top status bar $img = ""._(  "; $himg = ""._(  "; + echo ""; echo ""; $indicator = "$path_to_root/themes/".user_theme(). "/images/ajax-loader.gif"; - echo ""; + echo ""; echo "
" . $db_connections[$_SESSION["wa_current_user"]->company]["name"] . " | " . $_SERVER['SERVER_NAME'] . " | " . $_SESSION["wa_current_user"]->name . "" . _("Preferences") . "   \n"; echo " " . _("Change password") . "   \n"; @@ -85,7 +84,6 @@ echo "
"; } echo ""; - if ($no_menu) echo "
"; elseif ($title && !$is_index) @@ -100,7 +98,7 @@ function menu_footer($no_menu, $is_index) { - global $version, $allow_demo_mode, $app_title, $power_url, + global $version, $allow_demo_mode, $app_title, $power_url, $power_by, $path_to_root, $Pagehelp, $Ajax; include_once($path_to_root . "/includes/date_functions.inc"); @@ -125,7 +123,7 @@ { echo "\n"; echo "\n"; - echo "\n"; + echo "\n"; echo "\n"; echo "\n"; echo "\n"; @@ -133,7 +131,7 @@ if ($allow_demo_mode==true) { echo "\n"; - //echo "\n"; + //echo "\n"; echo "\n"; } echo "

\n"; @@ -211,6 +209,6 @@ echo ""; } echo ""; - } -} + } + } ?> \ No newline at end of file -- 2.30.2