X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=view%2Ftheme%2Ffrio%2Fphp%2Fdefault.php;h=b297fcb48174629de382d2609c542ec5835e8039;hb=e17db489eee549f47c39c9b5494063476ed4aeb0;hp=148f60c23acbc2111d68fa411b52b73fc32c8fc7;hpb=ec9f22de9275190dcf50798067a896470677c44a;p=friendica.git diff --git a/view/theme/frio/php/default.php b/view/theme/frio/php/default.php index 148f60c23a..b297fcb481 100644 --- a/view/theme/frio/php/default.php +++ b/view/theme/frio/php/default.php @@ -19,7 +19,11 @@ if (!isset($minimal)) { $minimal = false; } +$basepath = $a->getURLPath() ? "/" . $a->getURLPath() . "/" : "/"; +$frio = "view/theme/frio"; $view_mode_class = ($a->is_mobile || $a->is_tablet) ? 'mobile-view' : 'desktop-view'; +$is_singleuser = Config::get('system', 'singleuser'); +$is_singleuser_class = $is_singleuser ? "is-singleuser" : "is-not-singleuser"; ?>
@@ -28,25 +32,19 @@ $view_mode_class = ($a->is_mobile || $a->is_tablet) ? 'mobile-view' : 'desktop-v getURLPath() ? "/" . $a->getURLPath() . "/" : "/"; - $frio = "view/theme/frio"; - // Because we use minimal for modals the header and the included js stuff should be only loaded // if the page is an standard page (so we don't have it twice for modals) // /// @todo Think about to move js stuff in the footer - if (!$minimal && x($page, 'htmlhead')) { + if (!$minimal && !empty($page['htmlhead'])) { echo $page['htmlhead']; } // Add the theme color meta // It makes mobile Chrome UI match Frio's top bar color. - $uid = $a->profile_uid; - if (is_null($uid)) { - $uid = Profile::getThemeUid(); - } + $uid = Profile::getThemeUid($a); $scheme = PConfig::get($uid, 'frio', 'scheme', PConfig::get($uid, 'frio', 'schema')); - if ($scheme && ($scheme != '---')) { + if ($scheme && is_string($scheme) && $scheme != '---') { if (file_exists('view/theme/frio/scheme/' . $scheme . '.php')) { $schemefile = 'view/theme/frio/scheme/' . $scheme . '.php'; require_once $schemefile; @@ -54,21 +52,19 @@ $view_mode_class = ($a->is_mobile || $a->is_tablet) ? 'mobile-view' : 'desktop-v } else { $nav_bg = PConfig::get($uid, 'frio', 'nav_bg'); } - if (empty($nav_bg)) { + + if (empty($nav_bg) || !is_string($nav_bg)) { $nav_bg = "#708fa0"; } - echo ' - '; - $is_singleuser = Config::get('system','singleuser'); - $is_singleuser_class = $is_singleuser ? "is-singleuser" : "is-not-singleuser"; + echo ''; ?> "> Skip to main content is_mobile || $a->is_tablet) ? 'mobile-view' : 'desktop-v // special minimal style for modal dialogs if ($minimal) { ?> -