aboutsummaryrefslogtreecommitdiffstats
path: root/include/nav.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-10-08 19:43:03 -0700
committerzotlabs <mike@macgirvin.com>2017-10-08 19:43:03 -0700
commit23812e5b48b7a4d4f0c275c0fbb3d244a582397c (patch)
treeaecb91a4be080ecd8cfaf6bfccf3a1613d88588c /include/nav.php
parentc37908f344ecbac3ee60e3e36701161a4047d639 (diff)
downloadvolse-hubzilla-23812e5b48b7a4d4f0c275c0fbb3d244a582397c.tar.gz
volse-hubzilla-23812e5b48b7a4d4f0c275c0fbb3d244a582397c.tar.bz2
volse-hubzilla-23812e5b48b7a4d4f0c275c0fbb3d244a582397c.zip
ability to pin apps to the navbar when using named navbars
Diffstat (limited to 'include/nav.php')
-rw-r--r--include/nav.php13
1 files changed, 11 insertions, 2 deletions
diff --git a/include/nav.php b/include/nav.php
index 622717347..588104eda 100644
--- a/include/nav.php
+++ b/include/nav.php
@@ -261,10 +261,18 @@ EOT;
if(\App::$nav_sel['active'] == $app['name'])
$app['active'] = true;
- if($is_owner)
+ if($is_owner) {
$nav_apps[] = Zlib\Apps::app_render($app,'nav');
- elseif(! $is_owner && strpos($app['requires'], 'local_channel') === false)
+ if(strpos($app['categories'],'navbar_' . $template)) {
+ $navbar_apps[] = Zlib\Apps::app_render($app,'navbar');
+ }
+ }
+ elseif(! $is_owner && strpos($app['requires'], 'local_channel') === false) {
$nav_apps[] = Zlib\Apps::app_render($app,'nav');
+ if(strpos($app['categories'],'navbar_' . $template)) {
+ $navbar_apps[] = Zlib\Apps::app_render($app,'navbar');
+ }
+ }
}
$c = theme_include('navbar_' . $template . '.css');
@@ -294,6 +302,7 @@ EOT;
'$help' => t('@name, #tag, ?doc, content'),
'$pleasewait' => t('Please wait...'),
'$nav_apps' => $nav_apps,
+ '$navbar_apps' => $navbar_apps,
'$channel_menu' => get_config('system','channel_menu'),
'$channel_thumb' => ((App::$profile) ? App::$profile['thumb'] : ''),
'$channel_apps' => $channel_apps,