Table of Contents
DocNavigation Plugin
Compatible with DokuWiki
- 2023-04-04 "Jack Jackrum" yes
- 2022-07-31 "Igor" yes
- 2020-07-29 "Hogfather" yes
- 2018-04-22 "Greebo" yes
Similar to pagenav
Installation
Search and install the plugin using the Extension Manager. Refer to Plugins on how to install plugins manually.
Usage
The syntax defines which pages are referred to as previous and next pages. A start page or page with an overview can be provided in between.
<- namespace:previous_page ^ namespace:startpage ^ namespace:next page ->
or, alternatively, only different syntax (for example needed in combination with ckgedit plugin)
<< namespace:previous_page ^ namespace:startpage ^ namespace:next page >>
And at the start page an auto-generated table of contents can be put using
<doctoc start= yournamespace:firstpage>
Syntax
Page navigation
Urls are shown with default link names derived from url or useheading setting.
<-namespace:previous^namespace:startpage^namespace:next->
Urls are shown with the given names.
<-previous|Your previous page^startpage|Overview^other_page|Navigate to next page ->
Example of navigation added by the DocNavigation Plugin. Here the useheading config is enabled such that the page headings are used as link name.
Table of contents generated from linked pages
A Table of Contents of the linked pages can be created with <doctoc optionname=value[, more=..]>
.
<doctoc> <doctoc start=firstpage, includeheadings=2-3>
possible options:
Option | Description |
---|---|
start=<pageid> | Pageid of the first page with page navigation, if left out the page navigation is searched on the current page. |
includeheadings=<topheading>-<maxheading> | Includes the given heading levels of a page in the table of content. e.g 2-3 Default: 2 (levels are numbered from 1 to 5) |
hidepagelink=<0 or 1> | Hide the page links, but shows default the first two levels of the table of content. With includeheadings setting the number of levels can be changed. If only includeheadings is used, the page links are shown, which can result in duplicated titles if level 1 is shown. |
useheading=<0 or 1> | Overrules the 'navigation' case of the useheading setting. |
Development
Change Log
- update plugin.info.txt (2023-01-23 00:25)
- only check link back between page navigation syntaxes, not between do… (2023-01-23 00:07)
- if useheading=nav or off, then everywhere 'start' was shown as title (2023-01-22 22:13)
- update plugin.info.txt (2022-10-06 00:36)
- readd the hash in the shown links. Fixes #19 (2022-10-06 00:29)
- Fix double resolving of pageids. Fixes #20 (2022-10-05 23:59)
- reformatting all code to dokuwiki style (2022-10-05 23:56)
- update plugin.info.txt (2022-10-05 23:34)
Bugs and feature requests
Please report all your bugs and feature requests at the issue tracker.