aboutsummaryrefslogtreecommitdiffstats
path: root/include/nav.php
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2016-04-21 23:03:09 +0200
committerMario Vavti <mario@mariovavti.com>2016-04-21 23:03:09 +0200
commitd7f4bfedd5164596504d17b1ef4b8597a1304d98 (patch)
treeac790232f1816b74d510c5da2483b8f196386e25 /include/nav.php
parent391ed8655ebf25c2feb6cef59970778b99351df8 (diff)
downloadvolse-hubzilla-d7f4bfedd5164596504d17b1ef4b8597a1304d98.tar.gz
volse-hubzilla-d7f4bfedd5164596504d17b1ef4b8597a1304d98.tar.bz2
volse-hubzilla-d7f4bfedd5164596504d17b1ef4b8597a1304d98.zip
some fixes for contextual help and disable transition animation for now - it looked really wired because main moved with a different speed than help-content and help-content can not be displayed under the panel as it is implemented now.
Diffstat (limited to 'include/nav.php')
-rw-r--r--include/nav.php17
1 files changed, 11 insertions, 6 deletions
diff --git a/include/nav.php b/include/nav.php
index 9d8fdc30e..c59aaae37 100644
--- a/include/nav.php
+++ b/include/nav.php
@@ -150,10 +150,15 @@ EOT;
$help_url = z_root() . '/help?f=&cmd=' . App::$cmd;
if(! get_config('system','hide_help')) {
- require_once('include/help.php');
- $context_help = load_context_help();
- $enable_context_help = get_config('system','enable_context_help') || 0;
- $nav['help'] = array($help_url, t('Help'), "", t('Help and documentation'),'help_nav_btn',$context_help,$enable_context_help);
+ $context_help = '';
+ $enable_context_help = ((intval(get_config('system','enable_context_help')) === 1 || get_config('system','enable_context_help') === false) ? true : false);
+ if($enable_context_help === true) {
+ require_once('include/help.php');
+ $context_help = load_context_help();
+ //direct directly to /help if $context_help is empty - this can be removed once we have context help for all modules
+ $enable_context_help = (($context_help) ? true : false);
+ }
+ $nav['help'] = array($help_url, t('Help'), "", t('Help and documentation'), 'help_nav_btn', $context_help, $enable_context_help);
}
if(! UNO)
@@ -238,8 +243,8 @@ $powered_by = '';
$tpl = get_markup_template('nav_header.tpl');
App::$page['htmlhead'] .= replace_macros($tpl, array(
- '$enable_context_help' => ((intval(get_config('system','enable_context_help')) === 1 || get_config('system','enable_context_help') === false) ? true : false)
- ));
+ '$enable_context_help' => $enable_context_help
+ ));
$tpl = get_markup_template('nav.tpl');