template:dokukitv2
Table of Contents
DokuKITv2 Template
Compatible with DokuWiki
- 2023-04-04 "Jack Jackrum" unknown
- 2022-07-31 "Igor" unknown
- 2020-07-29 "Hogfather" yes
- 2018-04-22 "Greebo" yes
Similar to dokukit
What is this?
A dokuwiki template that imitates the new KIT design introduced in August 2020.
For the old KIT-design see dokukit.
Features:
- static menu using JSON input
- dynamic menu built from the dokuwiki index
- breadcrumps showing the current trace
- mobile friendly
Install
Either install automatically via Dokuwikis admin interface or install by cloning
git clone https://github.com/particleKIT/dokuKITv2.git dokukitv2
into the lib/tpl
directory of you dokuwiki instance and then enabling in the admin interface (check file permissions!).
Static menu
- select
file
for themenu
-option in the admin panel - specify a dokuwiki page used build the static menu using the
menusite
config in the admin panel - put a JSON menu into that file encapsulated by
<MENU> …JSON…</MENU>
- the JSON code should contain three associative array
level1..3
that specify menu point on the respective level - menu entries of level
n+1
that should be associated with those of leveln
need to have the same key (see example below) - each key can only be used once, use anchors (
:page#example
) to make them unique again - amongst anchors also further GET parameters can be specified (e.g.
:page?key=value#anchor
)
Example
<MENU> { "level1": { ":start": "Startpage", ":staff": "Staff", ":research": "Research" }, "level2": { ":staff": { ":staff:profs" : "Principal Investigators", ":staff:students" : "Students" }, ":research": { ":research:pubs" : "Publications", ":research:these" : "Theses" } }, "level3": { ":staff:profs": { ":profs:erika.mustermfrau": "Prof. Dr. Erika Musterfrau", ":profs:max.mustermann": "Prof. Dr. Max Mustermann" }, ":research:pubs": { "https://preprint.server.de": "Preprints", "https://journal.server.de": "Peer Review" }, ":research:these": { ":research:theses:phd": "PhD Theses", ":research:theses:dipl": "Diploma Theses" } } } </MENU>
The “level4
” which is sometimes used in the original KIT design is not supported.
If you get a JSON parser error, consider using a JSON online parser to get a more meaningful error message.
Dynamic Menu
- select
index
for themenu
-option in the admin panel - give a comma separated list of dokuwiki pages for
cleanindexlist
- these pages are excluded from the navigation
- ACLs should be taken care of automatically
Sites using this Template
template/dokukitv2.txt · Last modified: 2020-09-25 17:00 by Aleksandr