DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:simplenavi

simplenavi Plugin

Compatible with DokuWiki

  • 2024-02-06 "Kaos" unknown
  • 2023-04-04 "Jack Jackrum" yes
  • 2022-07-31 "Igor" yes
  • 2020-07-29 "Hogfather" no

plugin Create a simple navigation tree based on namespaces

Last updated on
2023-11-13
Provides
Syntax
Repository
Source

Similar to indexmenu, navi, simpleindex

Tagged with menu, navigation

This plugin creates a tree of links based on the wiki's namespace structure and is intended to be used in the sidebar of any template. It looks similar to the Page Index but with namespaces linking directly to their respective start pages. The tree is opened based on the currently opened page.

The plugin honors ACLs and hidepages settings.

Download and Installation

A CosmoCode Plugin

Search and install the plugin using the Extension Manager. Refer to Plugins on how to install plugins manually.

Syntax and Usage

Use the following code to embed the navigation in your sidebar page:

{{simplenavi>}}

You can optionally give a namespace at which the navigation tree should start (e.g. useful for building different navigations for different language namespaces):

{{simplenavi>ns1:ns2}}

Example:

{{simplenavi>animals:insects}}

Additional options can be given separated by spaces.

{{simplenavi>animals:insects filter}}

The filter option will add a text input field which allows for filtering the top level of the tree.

{{simplenavi>animals:insects home}}

The home option will wrap all found content under the start page of the given name space. Useful when composing menus from different simplenavi calls.

Configuration

Use the DokuWiki configuration manager to change the behaviour of the plugin.

  • natsort - Use natural sorting instead of simple string comparisons. There is probably no reason to disable this.
  • nsfirst - Sort namespaces before pages. When disabled, namespaces are sorted among pages based on their names.
  • usetitle - When enabled, sorting happens based on page titles instead of page IDs. When enabled, output will also use page titles in the resulting links. Note: this behavior is now independent of the useheading option.

Development

A public git repository is available at https://github.com/cosmocode/simplenavi

Changelog

Bugs and feature request

Please report issues in the bug tracker at https://github.com/cosmocode/simplenavi/issues

plugin/simplenavi.txt · Last modified: by Aleksandr

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki