show doc section heading in titlebar

This commit is contained in:
Mario Vavti 2016-12-11 21:43:27 +01:00
parent 542e487b69
commit 0a21ffbfec
2 changed files with 14 additions and 2 deletions

View File

@ -76,12 +76,24 @@ class Help extends \Zotlabs\Web\Controller {
killme(); killme();
} }
$headings = [
'about' => t('About'),
'member' => t('Members'),
'admin' => t('Administrators'),
'developer' => t('Developers'),
'tutorials' => t('Tutorials')
];
if(array_key_exists(argv(1), $headings))
$heading = $headings[argv(1)];
$content = get_help_content(); $content = get_help_content();
return replace_macros(get_markup_template('help.tpl'), array( return replace_macros(get_markup_template('help.tpl'), array(
'$title' => t('$Projectname Documentation'), '$title' => t('$Projectname Documentation'),
'$tocHeading' => t('Contents'), '$tocHeading' => t('Contents'),
'$content' => $content '$content' => $content,
'$heading' => $heading
)); ));
} }

View File

@ -1,6 +1,6 @@
<div id="help-content" class="generic-content-wrapper"> <div id="help-content" class="generic-content-wrapper">
<div class="section-title-wrapper"> <div class="section-title-wrapper">
<h2>{{$title}}</h2> <h2>{{$title}}: {{$heading}}</h2>
</div> </div>
<div class="section-content-wrapper" id="doco-content"> <div class="section-content-wrapper" id="doco-content">
<h1 class="fakelink" id="doco-top-toc-heading"><span onclick="docoTocToggle(); return false;"> <h1 class="fakelink" id="doco-top-toc-heading"><span onclick="docoTocToggle(); return false;">