diff --git a/themes/default/css.php b/themes/default/css.php index 30b647de20..898ecbb3f8 100644 --- a/themes/default/css.php +++ b/themes/default/css.php @@ -829,8 +829,7 @@ $default_login = ($_REQUEST['login'] == 'default') ? true : false; } #login_logo { - width: 250px; - height: auto; + text-decoration: none; } a.login_link { diff --git a/themes/default/images/logo_login.png b/themes/default/images/logo_login.png new file mode 100644 index 0000000000..1dcd520efa Binary files /dev/null and b/themes/default/images/logo_login.png differ diff --git a/themes/default/template.php b/themes/default/template.php index 24d6530e15..3ebd56548c 100644 --- a/themes/default/template.php +++ b/themes/default/template.php @@ -21,19 +21,19 @@ if (strlen(PROJECT_PATH) > 0) { $php_self_dir = substr($php_self_dir, strlen(PROJECT_PATH), strlen($php_self_dir)); } -?> - - - - - - - - - - -\n"; +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; + +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; + //load custom css if ($_SESSION['theme']['custom_css']['text'] != '') { echo "\n\n"; @@ -42,18 +42,17 @@ //set fav icon $favicon = (isset($_SESSION['theme']['favicon']['text'])) ? escape($_SESSION['theme']['favicon']['text']) : '/themes/default/favicon.ico'; echo "\n"; -?> -<!--{title}--> +echo "<!--{title}-->\n"; + +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; +echo "\n"; - - - - - - - -/resources/fonts/web_font_loader.php?v=".escape($font_loader_version)."'>\n"; } ?> + - - - - \n"; +echo "\n"; + //add multilingual support $language = new text; $text = $language->get(null,'themes/default'); -?> - +echo "\n"; -
+echo "
\n"; - 0 && permission_exists("domain_select") && count($_SESSION['domains']) > 1) { - ?> -
- -
-
- - ".$text['theme-title-domains']." (".sizeof($_SESSION['domains']).")"; - ?> -

- -
-
- "; - echo "".escape($domain['domain_name'])."\n"; - if ($domain['domain_description'] != '') { - echo " - ".escape($domain['domain_description'])."\n"; - } - echo "
\n"; - $ary_domain_names[] = escape($domain['domain_name']); - $ary_domain_descs[] = str_replace('"','\"',escape($domain['domain_description'])); - } - ?> -
- + if (file_exists($_SERVER["DOCUMENT_ROOT"]."/app/domains/domains.php")) { + $href = '/app/domains/domains.php'; + } + else { + $href = '/core/domain_settings/domains.php'; + } + echo "".$text['theme-title-domains']." (".sizeof($_SESSION['domains']).")"; + + echo "

\n"; + echo " \n"; + echo "
\n"; + echo "
\n"; + + $bgcolor1 = "#eaedf2"; + $bgcolor2 = "#fff"; + foreach($_SESSION['domains'] as $domain) { + $bgcolor = ($bgcolor == $bgcolor1) ? $bgcolor2 : $bgcolor1; + $bgcolor = ($domain['domain_uuid'] == $_SESSION['domain_uuid']) ? "#eeffee" : $bgcolor; + echo "
"; + echo "".escape($domain['domain_name'])."\n"; + if ($domain['domain_description'] != '') { + echo " - ".escape($domain['domain_description'])."\n"; + } + echo "
\n"; + $ary_domain_names[] = escape($domain['domain_name']); + $ary_domain_descs[] = str_replace('"','\"',escape($domain['domain_description'])); + } + + echo "
\n"; + + echo " \n"; + + echo " \n"; + echo "\n"; - - - \n"; echo "
\n"; echo " \n"; @@ -434,313 +430,318 @@ echo "\n"; - if (!$default_login) { +if (!$default_login) { - //*************** BOOTSTRAP MENU ******************************** - function show_menu($menu_array, $menu_style, $menu_position) { - global $text; - - //determine menu behavior - switch ($menu_style) { - case 'inline': - $menu_type = 'default'; - $menu_width = 'calc(100% - 20px)'; - $menu_brand = false; - $menu_corners = null; - break; - case 'static': - $menu_type = 'static-top'; - $menu_width = 'calc(100% - 40px)'; - $menu_brand = true; - $menu_corners = "style='-webkit-border-radius: 0 0 4px 4px; -moz-border-radius: 0 0 4px 4px; border-radius: 0 0 4px 4px;'"; - break; - case 'fixed': - default: - $menu_position = ($menu_position != '') ? $menu_position : 'top'; - $menu_type = 'fixed-'.$menu_position; - $menu_width = 'calc(90% - 20px)'; - $menu_brand = true; - $menu_corners = null; - } - ?> - - - - db = $db; - $menu->menu_uuid = $_SESSION['domain']['menu']['uuid']; - $menu_array = $menu->menu_array(); - unset($menu); - - $menu_style = ($_SESSION['theme']['menu_style']['text'] != '') ? $_SESSION['theme']['menu_style']['text'] : 'fixed'; - $menu_position = ($_SESSION['theme']['menu_position']['text']) ? $_SESSION['theme']['menu_position']['text'] : 'top'; + //top fixed, static or inline boostrap menu + function show_menu($menu_array, $menu_style, $menu_position) { + global $text; + //determine menu behavior switch ($menu_style) { case 'inline': - $logo_align = ($_SESSION['theme']['logo_align']['text'] != '') ? $_SESSION['theme']['logo_align']['text'] : 'left'; - $logo_style = ($_SESSION['theme']['logo_style']['text'] != '') ? $_SESSION['theme']['logo_style']['text'] : ''; - echo "
\n"; - if ($_SERVER['PHP_SELF'] != PROJECT_PATH."/core/install/install.php") { - $logo = ($_SESSION['theme']['logo']['text'] != '') ? $_SESSION['theme']['logo']['text'] : PROJECT_PATH."/themes/default/images/logo.png"; - echo ""; - } - - show_menu($menu_array, $menu_style, $menu_position); + $menu_type = 'default'; + $menu_width = 'calc(100% - 20px)'; + $menu_brand = false; + $menu_corners = null; break; case 'static': - echo "
\n"; - show_menu($menu_array, $menu_style, $menu_position); + $menu_type = 'static-top'; + $menu_width = 'calc(100% - 40px)'; + $menu_brand = true; + $menu_corners = "style='-webkit-border-radius: 0 0 4px 4px; -moz-border-radius: 0 0 4px 4px; border-radius: 0 0 4px 4px;'"; break; case 'fixed': - show_menu($menu_array, $menu_style, $menu_position); - echo "
\n"; - break; - case 'side': - echo "\n"; - echo "
\n"; - echo "
\n"; - //header: left - echo "
\n"; - echo "
\n"; - //header: right - echo ""; - //current user - echo "\n"; - echo "".$text['theme-label-user'].": "; - echo "".$_SESSION['username'].""; - echo "\n"; - //domain name/selector (sm+) - if ($_SESSION["username"] != '' && permission_exists("domain_select") && count($_SESSION['domains']) > 1 && $_SESSION['theme']['domain_visible']['text'] == 'true') { - echo "\n"; - echo "".$text['theme-label-domain'].": "; - echo "".escape($_SESSION['domain_name']).""; - echo "\n"; - } - //logout icon - if ($_SESSION['username'] != '' && $_SESSION['theme']['logout_icon_visible']['text'] == "true") { - echo ""; - } - echo ""; - echo "
\n"; - break; + default: + $menu_position = ($menu_position != '') ? $menu_position : 'top'; + $menu_type = 'fixed-'.$menu_position; + $menu_width = 'calc(90% - 20px)'; + $menu_brand = true; + $menu_corners = null; } - ?> -
- -
- -
+ //begin navbar code + echo "\n"; } - // default login being used + + //determine menu configuration + $menu = new menu; + $menu->db = $db; + $menu->menu_uuid = $_SESSION['domain']['menu']['uuid']; + $menu_array = $menu->menu_array(); + unset($menu); + + $menu_style = ($_SESSION['theme']['menu_style']['text'] != '') ? $_SESSION['theme']['menu_style']['text'] : 'fixed'; + $menu_position = ($_SESSION['theme']['menu_position']['text']) ? $_SESSION['theme']['menu_position']['text'] : 'top'; + + switch ($menu_style) { + case 'inline': + $logo_align = ($_SESSION['theme']['logo_align']['text'] != '') ? $_SESSION['theme']['logo_align']['text'] : 'left'; + $logo_style = ($_SESSION['theme']['logo_style']['text'] != '') ? $_SESSION['theme']['logo_style']['text'] : ''; + echo "
\n"; + if ($_SERVER['PHP_SELF'] != PROJECT_PATH."/core/install/install.php") { + $logo = ($_SESSION['theme']['logo']['text'] != '') ? $_SESSION['theme']['logo']['text'] : PROJECT_PATH."/themes/default/images/logo.png"; + echo ""; + } + + show_menu($menu_array, $menu_style, $menu_position); + break; + case 'static': + echo "
\n"; + show_menu($menu_array, $menu_style, $menu_position); + break; + case 'fixed': + show_menu($menu_array, $menu_style, $menu_position); + echo "
\n"; + break; + case 'side': + echo "\n"; + echo "
\n"; + echo "
\n"; + //header: left + echo "
\n"; + echo "
\n"; + //header: right + echo ""; + //current user + echo "\n"; + echo "".$text['theme-label-user'].": "; + echo "".$_SESSION['username'].""; + echo "\n"; + //domain name/selector (sm+) + if ($_SESSION["username"] != '' && permission_exists("domain_select") && count($_SESSION['domains']) > 1 && $_SESSION['theme']['domain_visible']['text'] == 'true') { + echo "\n"; + echo "".$text['theme-label-domain'].": "; + echo "".escape($_SESSION['domain_name']).""; + echo "\n"; + } + //logout icon + if ($_SESSION['username'] != '' && $_SESSION['theme']['logout_icon_visible']['text'] == "true") { + echo ""; + } + echo ""; + echo "
\n"; + break; + } + + echo "
\n"; + echo " \n"; + echo "
\n"; + echo "\n"; + + echo "
\n"; //initial div from switch statement above + +} + +// default login being used +else { + + if ($_SESSION['theme']['logo_login']['text'] != '') { + $logo = $_SESSION['theme']['logo_login']['text']; + } + else if ($_SESSION['theme']['logo']['text'] != '') { + $logo = $_SESSION['theme']['logo']['text']; + } else { - $logo = (isset($_SESSION['theme']['logo']['text'])) ? $_SESSION['theme']['logo']['text'] : PROJECT_PATH."/themes/default/images/logo.png"; - ?> -
-
- -
- - - - + echo "
\n"; + echo "
\n"; + echo " \n"; + echo "
\n"; + echo "\n"; + + unset($_SESSION['background_image']); + +} + +echo "\n"; +echo "\n"; +?> \ No newline at end of file