diff --git a/syntax.php b/syntax.php index f1622b8..3c84f1f 100644 --- a/syntax.php +++ b/syntax.php @@ -98,11 +98,19 @@ class syntax_plugin_navigation extends DokuWiki_Syntax_Plugin { $output = ''; foreach ($node->getNodes() as $node) { /** @var DokuWikiNode $node */ + $title = (strlen($node->getMetaData('title')) > 0 ? $node->getMetaData('title') : $node->getName()); + $access = auth_quickaclcheck($node->getFullID()); if ($node instanceof DokuWikiPage) { - $output .= '
  • ' . $node->getName() . '
  • '; - } else { + if ($access > 0) { + $output .= '
  • ' . $title . '
  • '; + } + + } else if($node instanceof DokuWikiNameSpace) { + /** @var DokuWikiNameSpace $node */ if ($this->depth <= $this->maxDepth) { - $output .= '
  • ' . $node->getName() . '
  • '; + if ($access > 0) { + $output .= '
  • ' . $title . '
  • '; + } } } }