用户工具

站点工具


wiki:插件语法:indexmenu

差别

这里会显示出您选择的修订版和当前版本之间的差别。

到此差别页面的链接

两侧同时换到之前的修订记录前一修订版
后一修订版
前一修订版
wiki:插件语法:indexmenu [2026/10/13 22:06] – 外部编辑 127.0.0.1wiki:插件语法:indexmenu [2026/10/15 21:29] (当前版本) – 外部编辑 127.0.0.1
行 16: 行 16:
 downloadurl: https://github.com/samuelet/indexmenu/archive/master.zip downloadurl: https://github.com/samuelet/indexmenu/archive/master.zip
 donationurl: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=102873 donationurl: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=102873
----- +--- 
- +^ :!: If you use the Indexmenu's option 'js' in the Hogfather release (June 2020+), you have to disable the [defer_js feature flag](config:defer_js). The indexmenu plugin does not support deferred javascript loading at the moment.    Work-in-progress: [issue #230](https://github.com/samuelet/indexmenu/issues/230)  ^
-^ :!: If you use the Indexmenu's option 'js' in the Hogfather release (June 2020+), you have to disable the [defer_js feature flag](config:defer_js). The indexmenu plugin does not support deferred javascript loading at the moment.\\ \\ Work-in-progress: [issue #230](https://github.com/samuelet/indexmenu/issues/230)  ^+
  
 This plugin allows you to insert a fully customizable index or a list of pages starting from a specified namespace. This plugin allows you to insert a fully customizable index or a list of pages starting from a specified namespace.
-It should be useful in DokuWiki sites where pages are organized by [namespaces](:namespaces).+It should be useful in DokuWiki sites where pages are organized by [namespaces](namespaces).
 Main features are: Main features are:
   * Fully customizable with a lot of [flexible options](.:indexmenu#syntax), but easy to use and configure for standard needs.   * Fully customizable with a lot of [flexible options](.:indexmenu#syntax), but easy to use and configure for standard needs.
行 34: 行 33:
   * Hide namespaces/pages according to [ACLs](ACLs) and plugin [settings](.indexmenu#skip_index).   * Hide namespaces/pages according to [ACLs](ACLs) and plugin [settings](.indexmenu#skip_index).
  
-Themed indexmenu based on the Javascript index builder:\\ +Themed indexmenu based on the Javascript index builder:\ 
-![indexmenu1.jpg](http://samuele.netsons.org/dokuwiki/media/indexmenu1.jpg)\\ +![indexmenu1.jpg](http://samuele.netsons.org/dokuwiki/media/indexmenu1.jpg)\ 
-Indexmenu based on Dokuwikis index builder:\\+Indexmenu based on Dokuwikis index builder:\
 ![indexmenu2.jpg](http://samuele.netsons.org/dokuwiki/media/indexmenu2.jpg) ![indexmenu2.jpg](http://samuele.netsons.org/dokuwiki/media/indexmenu2.jpg)
  
行 51: 行 50:
  
 ### Examples: ### Examples:
-|Root namespace. Expands all |`%%![indexmenu>:](indexmenu>:)%%` | + 
-|Current namespace. Show only current level, don't expand any nodes. |`%%![indexmenu>.#1](indexmenu>.#1)%%` | +| Root namespace. Expands all | `%%{{indexmenu>:}}%%` | 
-|Parent namespace. Show parent namespace ("uplink") and current level, don't expand any nodes. |`%%![indexmenu>..:#1](indexmenu>..:#1)%%` | +| --- | --- | 
-|`wiki` namespace, expand containing namespaces, not subnamespaces.\\ Using the themed Javascript indexmenu. |`%%![js](indexmenu>:wiki#1)%%` |+| Current namespace. Show only current level, don't expand any nodes. | `%%{{indexmenu>.#1}}%%` | 
 +| Parent namespace. Show parent namespace ("uplink") and current level, don't expand any nodes. | `%%{{indexmenu>..:#1}}%%` | 
 +| `wiki` namespace, expand containing namespaces, not subnamespaces.  Using the themed Javascript indexmenu. | `%%{{indexmenu>:wiki#1\|js}}%%` |
  
  
行 60: 行 61:
 **Minimum syntax:** **Minimum syntax:**
  
-  * `**%%![indexmenu>.](indexmenu>.)%%**` +  * `**%%{{indexmenu>.}}%%**` 
-  * `**%%![indexmenu>:](indexmenu>:)%%**`+  * `**%%{{indexmenu>:}}%%**`
   * `**%%{{indexmenu>|}}%%**`   * `**%%{{indexmenu>|}}%%**`
  
-That means this `**%%![indexmenu](indexmenu)%%**` and this `**%%![indexmenu>](indexmenu>)%%**` do not work.+That means this `**%%{{indexmenu}}%%**` and this `**%%{{indexmenu>}}%%**` do not work.
  
 **Basic syntax usage:** **Basic syntax usage:**
  
-^ Main                                                         ^ Options                                                       ^ + 
-| **%%{{%%indexmenu>ns[#n]** <sub>[ns1[#n] ns2[#n] ...]</sub>  | **%%|%%** //<sub>[js[#theme]] [tsort] ...</sub> //**%%}}%%**  |+| Main | Options | 
 +| --- | --- | 
 +| **%%{{%%indexmenu>ns[#n]** <sub>[ns1[#n] ns2[#n] ...]</sub> | **%%\|%%** *<sub>[js[#theme]] [tsort] ...</sub>* **%%}}%%** |
 Arguments inside `[]` parenthesis are optional. The `#` char is always required with related options. Arguments inside `[]` parenthesis are optional. The `#` char is always required with related options.
  
-:!: All the syntax options can be easily accessed with the indexmenu picker in the [edit window](:edit window) [toolbar](:toolbar).+:!: All the syntax options can be easily accessed with the indexmenu picker in the [edit window](edit window) [toolbar](toolbar).
  
  
 ## Full syntax ## Full syntax
 Settings **before the "|"** separator: Settings **before the "|"** separator:
-^Main ^Action ^Note| + 
-^ //''ns''//     | //**Main namespace**// name. Index starts from here. Syntax complies with DokuWiki [[:namespaces#creating namespaces|namespaces]] paths.| "**.**" refers to the namespace of the page containing the indexmenu syntax and **not** to the current DokuWiki namespace context ((the namespace of the page displayed by a user who is navigating your site)) (see the **//context//** option for this feature). "**..**" or an empty value shows the root site namespace.| +| Main | Action | Note | 
-^ //''#n''//             | **n** is a number that specifies how many namespace levels to display open under the //**main namespace**//.| If it's not defined then the whole tree, till the deeper node, will be open. If ''//0//'' or ''//1//'' it'll display only nodes under the main namespace. For example: "#2" will display "root:myns1:myns2" but will keep myns2 closed thus hiding "root:myns1:myns2:myns3". Optional.| +| --- | --- | --- | 
-^ //''ns1[#n] %%...%% nsn[#n]''// | A list //**of optional namespaces**// inside the //**main namespace**//. Every namespace will be opened or closed at the specified //**n**// level. Syntax complies with DokuWiki [[:namespaces#creating namespaces|namespaces]].| If **n** is not defined then all namespaces are open, if ''//0//'' they are closed. "**.**" refers to the namespace of the page containing the indexmenu syntax and **not** to the current DokuWiki namespace context ((the namespace of the page displayed by a user who is navigating your site)) (see the **//context//** option for this feature). "**..**" or an empty value shows the root site namespace. Optional.|+| _`ns`_ | _**Main namespace**_ name. Index starts from here. Syntax complies with DokuWiki [namespaces](namespaces#creating namespaces) paths. | "**.**" refers to the namespace of the page containing the indexmenu syntax and **not** to the current DokuWiki namespace context ((the namespace of the page displayed by a user who is navigating your site)) (see the **_context_** option for this feature). "**..**" or an empty value shows the root site namespace. | 
 +| _`#n`_ | **n** is a number that specifies how many namespace levels to display open under the _**main namespace**_. | If it's not defined then the whole tree, till the deeper node, will be open. If `_0_` or `_1_` it'll display only nodes under the main namespace. For example: "#2" will display "root:myns1:myns2" but will keep myns2 closed thus hiding "root:myns1:myns2:myns3". Optional. | 
 +| _`ns1[#n] %%...%% nsn[#n]`_ | A list _**of optional namespaces**_ inside the _**main namespace**_. Every namespace will be opened or closed at the specified _**n**_ level. Syntax complies with DokuWiki [namespaces](namespaces#creating namespaces). | If **n** is not defined then all namespaces are open, if `_0_` they are closed. "**.**" refers to the namespace of the page containing the indexmenu syntax and **not** to the current DokuWiki namespace context ((the namespace of the page displayed by a user who is navigating your site)) (see the **_context_** option for this feature). "**..**" or an empty value shows the root site namespace. Optional. |
  
 Optional settings **after the "|"** separator (separated by spaces): Optional settings **after the "|"** separator (separated by spaces):
-^Option ^Action ^Note| + 
-^ ''js'' \\ undo: ''nojs''          | JavaScript render method: the index is an expandable tree menu. Without the ''js'' option DokuWikis index renderer is used | Without //**n**//, all nodes are open, with it, nodes are open till //**n**// level.| +| Option | Action | Note | 
-^ //''#theme''// \\ undo: ''#default''          | Theme name for indexmenu icons | A theme is a set of icons inside ''//images//'' directory as described in [[.:indexmenu#Theme tutorial]]. Admins can download and share themes in admin panel. It works only in //**js**// e.g. //**js#tango**// | +| --- | --- | --- | 
-| Next options are available with or without _**js**_ option. ||| +| `js`   undo: `nojs` | JavaScript render method: the index is an expandable tree menu. Without the `js` option DokuWikis index renderer is used | Without _**n**_, all nodes are open, with it, nodes are open till _**n**_ level. | 
-^ ''navbar'' \\ undo: ''nonavbar''         | The tree opens itself automatically at the current page namespace. Useful in a navigation sidebar.| Without //**js**// option, the indexmenu page is never cached (just like the default DokuWiki index page) and the DokuWiki loading could be slower depending on the amount of child nodes displayed. | +| _`#theme`_   undo: `#default` | Theme name for indexmenu icons | A theme is a set of icons inside `_images_` directory as described in [Theme tutorial](.:indexmenu#Theme tutorial). Admins can download and share themes in admin panel. It works only in _**js**_ e.g. _**js#tango**_ | 
-^ ''context''  \\ undo: ''nocontext''   | [[:namespaces#creating namespaces|Relative]] //**main namespace**// and //**optional namespaces**// will refer to the current DokuWiki namespace context ((the namespace of the page displayed by a user who is navigating your site)) instead of to the namespace of the page containing the indexmenu syntax. Useful in a navigation sidebar.| The indexmenu page is now never cached so the DokuWiki loading could be slower depending on the amount of child nodes displayed (In //**js**// mode, when a lot of nodes are usually displayed, the //''max''// option is recommended). It automatically enable the //**nocookie**// option.| +| Next options are available with or without _**js**_ option. |  | | 
-^ ''tsort''   \\ undo: ''notsort'' | Sort (only) pages by title. | Useful when [[config:useheading]] is on. By default namespaces are **not** sorted, you need the **//nsort//** option for this.| +| `navbar`   undo: `nonavbar` | The tree opens itself automatically at the current page namespace. Useful in a navigation sidebar. | Without _**js**_ option, the indexmenu page is never cached (just like the default DokuWiki index page) and the DokuWiki loading could be slower depending on the amount of child nodes displayed. | 
-^ ''dsort''   \\ undo: ''nodsort''  | Sort (only) pages by date creation (first the oldest). | By default namespaces are **not** sorted, you need the **//nsort//** option for this.| +| `context`    undo: `nocontext` | [Relative](namespaces#creating namespaces) _**main namespace**_ and _**optional namespaces**_ will refer to the current DokuWiki namespace context ((the namespace of the page displayed by a user who is navigating your site)) instead of to the namespace of the page containing the indexmenu syntax. Useful in a navigation sidebar. | The indexmenu page is now never cached so the DokuWiki loading could be slower depending on the amount of child nodes displayed (In _**js**_ mode, when a lot of nodes are usually displayed, the _`max`_ option is recommended). It automatically enable the _**nocookie**_ option. | 
-^ ''msort[#meta]''   \\ undo: ''nomsort''  | Sort (only) pages by a custom [[:devel:metadata]] information. Without the ''#meta'' parameter, i.e. ''msort'', it looks for the custom sorting number specified with the ''%%{{indexmenu_n>N}}%%'' syntax  (see the below [[.indexmenu#metadata tag syntax]]).\\ With ''#meta'' parameter you can refer to the [[:devel:metadata#data structure|meta data structure]] (Array values are managed through the ":" separator, for example: ''msort#date:modified''). |By default, pages without metadata tag are sorted by page name (the default DokuWiki way), but you can override this behaviour adding also the tsort or dsort option in the indexmenu syntax. By default namespaces are **not** sorted, you need the **//nsort//** option for this.| +| `tsort`     undo: `notsort` | Sort (only) pages by title. | Useful when [useheading](config:useheading) is on. By default namespaces are **not** sorted, you need the **_nsort_** option for this. | 
-^ ''hsort''   \\ undo: ''nohsort'' | Sort the headpages as defined by config setting [[config:startpage]] to the top |msort overrules hsort | +| `dsort`     undo: `nodsort` | Sort (only) pages by date creation (first the oldest). | By default namespaces are **not** sorted, you need the **_nsort_** option for this. | 
-^ ''rsort''   \\ undo: ''norsort'' | Reverse the sorting of pages (change between ascending and descending). |By default namespaces are **not** sorted, you need the **//nsort//** option for this. | +| `msort[#meta]`     undo: `nomsort` | Sort (only) pages by a custom [metadata](devel:metadata) information. Without the `#meta` parameter, i.e. `msort`, it looks for the custom sorting number specified with the `%%{{indexmenu_n>N}}%%` syntax  (see the below [metadata tag syntax](.indexmenu#metadata tag syntax)).  With `#meta` parameter you can refer to the [meta data structure](devel:metadata#data structure) (Array values are managed through the ":" separator, for example: `msort#date:modified`). | By default, pages without metadata tag are sorted by page name (the default DokuWiki way), but you can override this behaviour adding also the tsort or dsort option in the indexmenu syntax. By default namespaces are **not** sorted, you need the **_nsort_** option for this. | 
-^ ''nsort''   \\ undo: ''nonsort'' | Also sort namespaces according to page sort options but grouped separately. | To use in //addition// to the above sort options. tsort, dsort, msort, hsort apply only for namespaces when using [[#namespaces_title_and_link_headpages|headpages]]. rsort is applicable always together with nsort.  | +| `hsort`     undo: `nohsort` | Sort the headpages as defined by config setting [startpage](config:startpage) to the top | msort overrules hsort | 
-^ ''nons''   \\ undo: ''ns''  | Exclude namespaces nodes from index. It shows only the pages. | Without **//js//**, the closing **//n//** namespace option prevents to display nodes below the **//n//** namespace level.| +| `rsort`     undo: `norsort` | Reverse the sorting of pages (change between ascending and descending). | By default namespaces are **not** sorted, you need the **_nsort_** option for this. | 
-^ ''nopg''  \\ undo: ''pg''  | Exclude pages nodes from index. It shows only the namespaces. | All namespace nodes will link to the start pages (as defined by [[config:startpage]] setting) | +| `nsort`     undo: `nonsort` | Also sort namespaces according to page sort options but grouped separately. | To use in _addition_ to the above sort options. tsort, dsort, msort, hsort apply only for namespaces when using [headpages](#namespaces_title_and_link_headpages). rsort is applicable always together with nsort. | 
-^ ''skipfile[+|=]/regexp/'' | Skip files matching the regexp. | ''skipfile**+**/../'' skips files defined with this regexp additional to [[#skip_files_in_index|global skip]] config. ''skipfile**=**/../'' replace the global skip config with regexp from this syntax. See the global config explanation for some regexp [[#skip_namespaces_in_index|examples]].| +| `nons`     undo: `ns` | Exclude namespaces nodes from index. It shows only the pages. | Without **_js_**, the closing **_n_** namespace option prevents to display nodes below the **_n_** namespace level. | 
-^ ''skipns[+|=]/regexp/'' | Skip namespaces matching the regexp. | Just like skipfile, but [[#skip_namespaces_in_index|namespaces]].| +| `nopg`    undo: `pg` | Exclude pages nodes from index. It shows only the namespaces. | All namespace nodes will link to the start pages (as defined by [startpage](config:startpage) setting) | 
-| Next options are _only_ available with _**js**_ option. ||| +| `skipfile[+\|=]/regexp/` | Skip files matching the regexp. | `skipfile**+**/../` skips files defined with this regexp additional to [global skip](#skip_files_in_index) config. `skipfile**=**/../` replace the global skip config with regexp from this syntax. See the global config explanation for some regexp [examples](#skip_namespaces_in_index). | 
-^ ''max#n//[#m]//'' \\ undo: ''nomax''  | If initially closed, the node at //**n**// level will retrieve all its child nodes through the AJAX mechanism when opened for the first time. Optionally, the nodes after the //**n**// level can be retrieved with AJAX every //**m**// sublevels instead of in one go.| It affects the server loading and speeds up the loading of pages in DokuWiki with an high amount of pages. It works only in //**js**//. Cookie are automatically disabled, just like with //**nocookie**//. | +| `skipns[+\|=]/regexp/` | Skip namespaces matching the regexp. | Just like skipfile, but [namespaces](#skip_namespaces_in_index). | 
-^ ''maxjs#//n//''  \\ undo: ''nomaxjs''   | It sets how many js tree levels to render when page loads. Remaining nodes are rendered (slightly slower) only when they are open by users, by  //**optional namespaces**// option, by cookies or by //**navbar**// option. | Default //**n**// is 1 so that it will speed up the page loading, above all with an high amount of pages. It affects only the user-client CPU speed, not the webserver load. It works only in //**js**// | +| Next options are _only_ available with _**js**_ option. |  | | 
-^ ''id#[random|ns|//number//]''   \\ undo: ''id#random''     | [[wp>HTTP_cookie|Cookie]] Identifier for a js indexmenu where the previously opened/closed nodes by a user are stored. | Useful when a page is uncached and you like the tree state is stored in cookie. (See //**nocookie**// for disabling cookies.)  Default the option ''//id#random//'' is active, also when the option is not specified in the syntax. You can apply self a number as unique identifier for your indexmenu  ( e.g. ''//id#20//'' ) or let generate a number unique for requested namespace with ''//id#ns//''. Read the [[.:indexmenu#Js does not remember its previous state]] section. **ATTENTION:** ID must be unique for every indexmenu in your DokuWiki site or you'll get strange js behaviors. Tree state storage with cookie only in //**js**// | +| `max#n`*`[#m]`*   undo: `nomax` | If initially closed, the node at _**n**_ level will retrieve all its child nodes through the AJAX mechanism when opened for the first time. Optionally, the nodes after the _**n**_ level can be retrieved with AJAX every _**m**_ sublevels instead of in one go. | It affects the server loading and speeds up the loading of pages in DokuWiki with an high amount of pages. It works only in _**js**_. Cookie are automatically disabled, just like with _**nocookie**_. | 
-^ ''nocookie''  \\ undo: ''cookie'' | Disable [[wp>HTTP_cookie|cookies]]. By default js indexmenu remember selected,open and closed nodes by user during navigation. With this option it doesn't remember them and the tree is blocked to its start status. | Tree state storage with cookie only in //**js**//| +| `maxjs#_n_`    undo: `nomaxjs` | It sets how many js tree levels to render when page loads. Remaining nodes are rendered (slightly slower) only when they are open by users, by  _**optional namespaces**_ option, by cookies or by _**navbar**_ option. | Default _**n**_ is 1 so that it will speed up the page loading, above all with an high amount of pages. It affects only the user-client CPU speed, not the webserver load. It works only in _**js**_ | 
-^ ''noscroll''   \\ undo: ''scroll''    | Disable the JavaScript scrolling feature when it doesn't fit the container width. It could solve visualization problems. | It works only in //**js**//| +| `id#[random\|ns\|_number_]`     undo: `id#random` | [Cookie](https://en.wikipedia.org/wiki/HTTP_cookie) Identifier for a js indexmenu where the previously opened/closed nodes by a user are stored. | Useful when a page is uncached and you like the tree state is stored in cookie. (See _**nocookie**_ for disabling cookies.)  Default the option `_id#random_` is active, also when the option is not specified in the syntax. You can apply self a number as unique identifier for your indexmenu  ( e.g. `_id#20_` ) or let generate a number unique for requested namespace with `_id#ns_`. Read the [Js does not remember its previous state](.:indexmenu#Js does not remember its previous state) section. **ATTENTION:** ID must be unique for every indexmenu in your DokuWiki site or you'll get strange js behaviors. Tree state storage with cookie only in _**js**_ | 
-^ ''notoc''  \\ undo: ''toc''        | Disable the TOC-preview feature. | ToC preview only available in //**js**//| +| `nocookie`    undo: `cookie` | Disable [cookies](https://en.wikipedia.org/wiki/HTTP_cookie). By default js indexmenu remember selected,open and closed nodes by user during navigation. With this option it doesn't remember them and the tree is blocked to its start status. | Tree state storage with cookie only in _**js**_ | 
-^ ''nomenu''  \\ undo: ''menu''       | Disable the contextmenu feature. | Context menu only available in //**js**//|+| `noscroll`     undo: `scroll` | Disable the JavaScript scrolling feature when it doesn't fit the container width. It could solve visualization problems. | It works only in _**js**_ | 
 +| `notoc`    undo: `toc` | Disable the TOC-preview feature. | ToC preview only available in _**js**_ | 
 +| `nomenu`    undo: `menu` | Disable the contextmenu feature. | Context menu only available in _**js**_ |
  
  
 ## Examples ## Examples
 A sample of an indexmenu JS index that could be used inside a navigation sidebar. Its initial status is blocked by the nocookie option, so, when the page is reloaded, it doesn't remember the open and closed nodes by the user.: A sample of an indexmenu JS index that could be used inside a navigation sidebar. Its initial status is blocked by the nocookie option, so, when the page is reloaded, it doesn't remember the open and closed nodes by the user.:
-<code>+ 
 +```
 {{indexmenu>..#1|js navbar nocookie}} {{indexmenu>..#1|js navbar nocookie}}
-</code>+``` 
  
 JS navigation index with "thread" theme where nodes after the third level are retrieved with Ajax every 2 sublevels. Pages are sorted by title and [custom sort](.indexmenu#Metadata tag syntax) number: JS navigation index with "thread" theme where nodes after the third level are retrieved with Ajax every 2 sublevels. Pages are sorted by title and [custom sort](.indexmenu#Metadata tag syntax) number:
-<code>+ 
 +```
 {{indexmenu>..#1|js#thread navbar max#3#2 tsort msort}} {{indexmenu>..#1|js#thread navbar max#3#2 tsort msort}}
-</code>+``` 
  
 Standard DokuWiki index showing only pages inside wiki:plugins and lower namespaces (max two levels): Standard DokuWiki index showing only pages inside wiki:plugins and lower namespaces (max two levels):
-<code>+ 
 +```
 {{indexmenu>:wiki:plugins#2|nons}} {{indexmenu>:wiki:plugins#2|nons}}
-</code>+``` 
  
 Js tree showing pages and namespaces both sorted by reverse title. For example,if "archive" contains stuff ("news","oldnews",etc) that you need to quickly organize by time, you could create numbered [headpages](.:indexmenu#Namespaces title and link (headpages)) for every namespace (i.e renaming "oldnews" in "news 2006", "news" in "news 2010" and so on) and sort them from new to older: Js tree showing pages and namespaces both sorted by reverse title. For example,if "archive" contains stuff ("news","oldnews",etc) that you need to quickly organize by time, you could create numbered [headpages](.:indexmenu#Namespaces title and link (headpages)) for every namespace (i.e renaming "oldnews" in "news 2006", "news" in "news 2010" and so on) and sort them from new to older:
-<code>+ 
 +```
 {{indexmenu>:archive#1|js tsort nsort rsort}} {{indexmenu>:archive#1|js tsort nsort rsort}}
-</code>+``` 
  
 Standard index showing the tree of the current context ((the namespace of the page displayed by a user who is navigating your site)) opened at the second level . Standard index showing the tree of the current context ((the namespace of the page displayed by a user who is navigating your site)) opened at the second level .
-<code>+ 
 +```
 {{indexmenu>playground#2|context}} {{indexmenu>playground#2|context}}
-</code>+``` 
  
 Show all current namespace pages . Show all current namespace pages .
-<code>+ 
 +```
 {{indexmenu>.:#1|context}} {{indexmenu>.:#1|context}}
-</code>+``` 
  
 JS tree showing all (and only) the namespaces of the "private" namespace sorted by date creation. "private" is relative and refers to the private namespace under the page containing the indexmenu syntax. JS tree showing all (and only) the namespaces of the "private" namespace sorted by date creation. "private" is relative and refers to the private namespace under the page containing the indexmenu syntax.
-<code>+ 
 +```
 {{indexmenu>private|js nopg dsort}} {{indexmenu>private|js nopg dsort}}
-</code>+``` 
  
  
 ### Metadata tag syntax ### Metadata tag syntax
 By default nodes on the same tree level are sorted by name (or by title/date if you use the tsort/dsort syntax), but you can also specify a custom sort number for every page inserting a metadata tag in the pages with this syntax: By default nodes on the same tree level are sorted by name (or by title/date if you use the tsort/dsort syntax), but you can also specify a custom sort number for every page inserting a metadata tag in the pages with this syntax:
-<code>+ 
 +```
 {{indexmenu_n>N}} {{indexmenu_n>N}}
-</code>+``` 
  
 Where `N` is a number. Where `N` is a number.
行 160: 行 183:
 You can change the order of this tree containing a mix of standard and [useheading](config:useheading) pages: You can change the order of this tree containing a mix of standard and [useheading](config:useheading) pages:
  
-<file>+ 
 +~~~
 -Root -Root
   |_don   |_don
行 168: 行 192:
   |_van   |_van
   |_vliet   |_vliet
-</file>+~~~ 
  
 in this way: in this way:
-<code>+ 
 +```
 {{indexmenu>..#1|msort}} {{indexmenu>..#1|msort}}
-</code> +``` 
-<file>+ 
 + 
 +~~~
 -Root -Root
   |_vliet                   {{indexmenu_n>1}}   |_vliet                   {{indexmenu_n>1}}
行 182: 行 210:
   |_pachuco   |_pachuco
   |_At the radar station    (headline title of the ":radar" page)   |_At the radar station    (headline title of the ":radar" page)
-</file>+~~~ 
  
 Pages without sort number, like the last three pages, are sorted by page name as default, but you can force a different sort: Pages without sort number, like the last three pages, are sorted by page name as default, but you can force a different sort:
-<code>+ 
 +```
 {{indexmenu>..#1|tsort msort}} {{indexmenu>..#1|tsort msort}}
-</code> +``` 
-<file>+ 
 + 
 +~~~
 -Root -Root
   |_vliet                   {{indexmenu_n>1}}   |_vliet                   {{indexmenu_n>1}}
行 196: 行 228:
   |_Mirror sessions         (headline title of the ":mirror" page)   |_Mirror sessions         (headline title of the ":mirror" page)
   |_pachuco   |_pachuco
-</file>+~~~ 
  
  
行 235: 行 268:
 You can choose a name for the page from which retrieve the title or use a self defined value: You can choose a name for the page from which retrieve the title or use a self defined value:
  
-^Value  ^Page  ^Example ^ + 
-|**any value** | The page inside the namespace | public(ns):myvalue(page) | +| Value | Page | Example | 
-|**:inside:** | a page with the same name of namespace, beneath the namespace | public(ns):public(page) |                                                                                +| --- | --- | --- | 
-|**:same:** | a page with the same name of namespace, at the same level of the namespace | public(page) <=> public(ns) | +| **any value** | The page inside the namespace | public(ns):myvalue(page) | 
-|**:start:** | the global [start](config:startpage) page name inside the namespace| public(ns):start(page) |+| **:inside:** | a page with the same name of namespace, beneath the namespace | public(ns):public(page) | 
 +| **:same:** | a page with the same name of namespace, at the same level of the namespace | public(page) <=> public(ns) | 
 +| **:start:** | the global [start](config:startpage) page name inside the namespace | public(ns):start(page) |
  
 You can specify more than one option using "," as separator. For every namespace, every value will be checked till the first existent headpage is found. You can specify more than one option using "," as separator. For every namespace, every value will be checked till the first existent headpage is found.
行 248: 行 283:
  
 ### Page index ### Page index
-When this option is not empty, the DokuWiki default [index](:index) page is replaced with a custom page, which you can fill yourself. For example you can add the indexmenu tree of your site.+When this option is not empty, the DokuWiki default [index](index) page is replaced with a custom page, which you can fill yourself. For example you can add the indexmenu tree of your site.
  
 Set this option with a DokuWiki page ID (i.e: `tools:index`), then create the page (i.e: `tools:index`) and put inside it an indexmenu syntax like this: Set this option with a DokuWiki page ID (i.e: `tools:index`), then create the page (i.e: `tools:index`) and put inside it an indexmenu syntax like this:
-<code>+ 
 +```
 {{indexmenu>..|navbar}} {{indexmenu>..|navbar}}
-</code>+``` 
 or or
-<code>+ 
 +```
 {{indexmenu>..|js navbar nocookie}} {{indexmenu>..|js navbar nocookie}}
-</code>+``` 
 You may also want to hide this page in any indexmenu trees with the [skip files in index](.:indexmenu#skip files in index) option. You may also want to hide this page in any indexmenu trees with the [skip files in index](.:indexmenu#skip files in index) option.
  
行 264: 行 303:
 You can show a custom message in place of the menu tree if it can not be rendered (i.e namespace doesn't exist) You can show a custom message in place of the menu tree if it can not be rendered (i.e namespace doesn't exist)
  
-The alias **%%![ns](ns)%%** is a shortcut for the requested namespace.+The alias **%%{{ns}}%%** is a shortcut for the requested namespace.
  
 Message supports the wiki syntax, so it's fully customizable. Don't use HTML code. Message supports the wiki syntax, so it's fully customizable. Don't use HTML code.
行 272: 行 311:
 The configuration setting `skip_index` let you globally hide namespaces (and their pages) in your indexmenu trees. The configuration setting `skip_index` let you globally hide namespaces (and their pages) in your indexmenu trees.
  
-Just fill this option with the ids of namespaces to skip using [Regular Expression](http://www.php.net/manual/en/reference.pcre.pattern.syntax.php).\\ +Just fill this option with the ids of namespaces to skip using [Regular Expression](http://www.php.net/manual/en/reference.pcre.pattern.syntax.php).\
 :!: Till V4.5, a namespaces full path has to be declared as a file system path (i.e.: "mydir/mysubdir") instead of DokuWiki IDs. :!: Till V4.5, a namespaces full path has to be declared as a file system path (i.e.: "mydir/mysubdir") instead of DokuWiki IDs.
  
 There are also some issues [About empty namespaces](.:indexmenu#About empty namespaces) that should be read.  There are also some issues [About empty namespaces](.:indexmenu#About empty namespaces) that should be read. 
  
-**Simple examples:**\\+**Simple examples:**\
 Skip any namespace whose ID contains the word `copyright` or `privatens:users`. Attention: `allprivatens:usersmich` will be also matched Skip any namespace whose ID contains the word `copyright` or `privatens:users`. Attention: `allprivatens:usersmich` will be also matched
-<code>+ 
 +```
 /(copyright|privatens:users)/ /(copyright|privatens:users)/
-</code>+``` 
 Skip the namespace whose ID is exactly `myusers:spaces`. Here the characters `^` and `$` marks the start and the end of the matched string. Skip the namespace whose ID is exactly `myusers:spaces`. Here the characters `^` and `$` marks the start and the end of the matched string.
-<code>+ 
 +```
 /^myusers:spaces$/ /^myusers:spaces$/
-</code>+``` 
  
  
 ### Skip Files in index ### Skip Files in index
 This configuration option `skip_file` let you to globally hide one or more pages in your indexmenu trees. This configuration option `skip_file` let you to globally hide one or more pages in your indexmenu trees.
-Just fill this option with the ids of pages to skip using [Regular Expression](http://www.php.net/manual/en/reference.pcre.pattern.syntax.php).\\ +Just fill this option with the ids of pages to skip using [Regular Expression](http://www.php.net/manual/en/reference.pcre.pattern.syntax.php).\
 :!: Till v4.5, pages are checked as DokuWiki text files (i.e.: start.txt). A page full path have to be declared as a file system path (i.e.: "mydir/start.txt") instead of DokuWiki IDs. :!: Till v4.5, pages are checked as DokuWiki text files (i.e.: start.txt). A page full path have to be declared as a file system path (i.e.: "mydir/start.txt") instead of DokuWiki IDs.
  
行 303: 行 346:
  
 # How to install # How to install
-Search and install the plugin using the [Extension Manager](plugin:extension). Refer to [Plugins](:Plugins) on how to install plugins manually.+Search and install the plugin using the [Extension Manager](plugin:extension). Refer to [Plugins](Plugins) on how to install plugins manually.
  
 Alternative download link: http://samuele.netsons.org/dokuwiki/media/indexmenu.zip Alternative download link: http://samuele.netsons.org/dokuwiki/media/indexmenu.zip
行 343: 行 386:
  
   * **2009-08-29 Version 4.6**:   * **2009-08-29 Version 4.6**:
-            * :!: _New Feature_: Namespace declaration complies with DokuWiki [namespaces](:namespaces#creating namespaces). **Important before upgrading from previous versions**: according to the new DokuWiki syntax, a simple _main namespace_ without relative declaration prefix (i.e: "playground") doesn't refer anymore to the subnamespace in the root namespace but in the **current** namespace. To refer to the root namespace, you need to prepend the ":" declaration to it.+            * :!: _New Feature_: Namespace declaration complies with DokuWiki [namespaces](namespaces#creating namespaces). **Important before upgrading from previous versions**: according to the new DokuWiki syntax, a simple _main namespace_ without relative declaration prefix (i.e: "playground") doesn't refer anymore to the subnamespace in the root namespace but in the **current** namespace. To refer to the root namespace, you need to prepend the ":" declaration to it.
             * _New Feature_: Added the _context_ option. It resolves relative requested namespaces starting from the current user location instead of the page containing the indexmenu syntax.             * _New Feature_: Added the _context_ option. It resolves relative requested namespaces starting from the current user location instead of the page containing the indexmenu syntax.
             * :!: _New Feature_: Changed skip_file and skip_index syntax to use DokuWiki ID instead of system paths. Thanks to Dmitry Katsubo.             * :!: _New Feature_: Changed skip_file and skip_index syntax to use DokuWiki ID instead of system paths. Thanks to Dmitry Katsubo.
行 378: 行 421:
  
 Simply create a subdirectory, for example `mytheme`, inside `indexmenu/images` and put inside it your icons following the default theme scheme: Simply create a subdirectory, for example `mytheme`, inside `indexmenu/images` and put inside it your icons following the default theme scheme:
-^ Icon               ^ Type                                    ^ Example: theme 'default'                                                               ^ + 
-| base.gif           | Root Folder                             | ![base.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/base.gif)           | +| Icon | Type | Example: theme 'default' | 
-| folderopen.gif     | Open folder without URL link            | ![folderopen.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folderopen.gif)     | +| --- | --- | --- | 
-| folder.gif         | Closed folder without URL link          | ![folder.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folder.gif)         | +| base.gif | Root Folder | ![base.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/base.gif) | 
-| folderhopen.gif    | Open folder with URL link (headpage)    | ![folderhopen.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folderhopen.gif)    | +| folderopen.gif | Open folder without URL link | ![folderopen.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folderopen.gif) | 
-| folderh.gif        | Closed folder with URL link (headpage)  | ![folderh.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folderh.gif)        | +| folder.gif | Closed folder without URL link | ![folder.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folder.gif) | 
-| page.gif           | Page                                    | ![page.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/page.gif)           | +| folderhopen.gif | Open folder with URL link (headpage) | ![folderhopen.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folderhopen.gif) | 
-| plus.gif           |                                         | ![plus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/plus.gif)           | +| folderh.gif | Closed folder with URL link (headpage) | ![folderh.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/folderh.gif) | 
-| minus.gif          |                                         | ![minus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/minus.gif)          | +| page.gif | Page | ![page.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/page.gif) | 
-| nolines_plus.gif   |                                         | ![nolines_plus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/nolines_plus.gif)   | +| plus.gif |  | ![plus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/plus.gif) | 
-| nolines_minus.gif  |                                         | ![nolines_minus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/nolines_minus.gif)  | +| minus.gif |  | ![minus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/minus.gif) | 
-| minusbottom.gif    |                                         | ![minusbottom.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/minusbottom.gif)    | +| nolines_plus.gif |  | ![nolines_plus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/nolines_plus.gif) | 
-| plusbottom.gif     |                                         | ![plusbottom.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/plusbottom.gif)     | +| nolines_minus.gif |  | ![nolines_minus.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/nolines_minus.gif) | 
-| join.gif           |                                         | ![join.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/join.gif)           | +| minusbottom.gif |  | ![minusbottom.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/minusbottom.gif) | 
-| joinbottom.gif     |                                         | ![joinbottom.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/joinbottom.gif)     | +| plusbottom.gif |  | ![plusbottom.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/plusbottom.gif) | 
-| line.gif           |                                         | ![line.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/line.gif)           | +| join.gif |  | ![join.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/join.gif) | 
-| empty.gif          | blank image to fill gap between lines   | ![empty.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/empty.gif)          |+| joinbottom.gif |  | ![joinbottom.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/joinbottom.gif) | 
 +| line.gif |  | ![line.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/line.gif) | 
 +| empty.gif | blank image to fill gap between lines | ![empty.gif](https://raw.github.com/samuelet/indexmenu/master/images/default/empty.gif) |
  
 Use your theme with **`js#mytheme`** syntax. Use your theme with **`js#mytheme`** syntax.
行 411: 行 456:
 Since the April 2013 plugin release you can add the **`nomenu`** option to indexmenu syntax to disable the contextmenu. Since the April 2013 plugin release you can add the **`nomenu`** option to indexmenu syntax to disable the contextmenu.
  
-Modification of menu in performed in `scripts/contextmenu.local.js`:\\+Modification of menu in performed in `scripts/contextmenu.local.js`:\
 (You can rename the example file from `scripts/contextmenu.local.js.example`) (You can rename the example file from `scripts/contextmenu.local.js.example`)
  
-  * Overriding menu entry \\ <code javascript>+  * Overriding menu entry\ 
 +```javascript
 indexmenu_contextmenu['all']['pg']['view'][0] = ['Custom Title']; indexmenu_contextmenu['all']['pg']['view'][0] = ['Custom Title'];
-</code> +``` 
-  * Adding menu entry \\ <code javascript>+ 
 +  * Adding menu entry\ 
 +```javascript
 indexmenu_contextmenu['all']['pg']['view'].splice( indexmenu_contextmenu['all']['pg']['view'].splice(
     3,      3, 
行 423: 行 471:
     ['Input new page', '"javascript: IndexmenuContextmenu.reqpage(\'"+index.config.urlbase+"\',\'"+index.config.sepchar+"\',\'"+node.dokuid+"\');"']     ['Input new page', '"javascript: IndexmenuContextmenu.reqpage(\'"+index.config.urlbase+"\',\'"+index.config.sepchar+"\',\'"+node.dokuid+"\');"']
  );  );
-</code>+``` 
   * Removing menu entry:   * Removing menu entry:
     * Override with empty array: `[]`     * Override with empty array: `[]`
行 433: 行 482:
   * `entryDescriptionArray` - array with description of a menu entry   * `entryDescriptionArray` - array with description of a menu entry
  
-**How to write utf8 chars, like èåäö, in the context menu file?**\\+**How to write utf8 chars, like èåäö, in the context menu file?**\
 A solution is to encode them yourself: Find your char at http://unicode.coeurlumiere.com, replace the last zero of the left code by the character in the upper row and prepend the result with `\u` : i.e. `\u00E3` for 'ã' A solution is to encode them yourself: Find your char at http://unicode.coeurlumiere.com, replace the last zero of the left code by the character in the upper row and prepend the result with `\u` : i.e. `\u00E3` for 'ã'
  
-------+---
 In the releases _before April_ 2013, you could fully customize those menus by editing these files in the 'jsmenu/' directory: In the releases _before April_ 2013, you could fully customize those menus by editing these files in the 'jsmenu/' directory:
  
-^File ^Loaded by^ + 
-|"menu.js" |anonymous user| +| File | Loaded by | 
-|"usrmenu.js" |authenticated user| +| --- | --- | 
-|"admmenu.js" |admin user((see [superuser](config:superuser)))|+| "menu.js" | anonymous user | 
 +| "usrmenu.js" | authenticated user | 
 +| "admmenu.js" | admin user((see [superuser](config:superuser))) |
  
 And to prevent to load the context menu, simply remove the indexmenu_contextmenu variable declared in the above menu files. And to prevent to load the context menu, simply remove the indexmenu_contextmenu variable declared in the above menu files.
行 452: 行 503:
  
 Some styles are: Some styles are:
-^Tag                  ^Comment                                        ^Mode  ^ + 
-|a.nodeFdUrl          |Namespace with URL link (headpage)             |js    | +| Tag | Comment | Mode | 
-|a.node               |Namespace without URL link                     |js    | +| --- | --- | --- | 
-|a.nodeUrl            |Page                                           |js    | +| a.nodeFdUrl | Namespace with URL link (headpage) | js | 
-|a.nodeSel            |Previous selected page or headpage highlight   |js    | +| a.node | Namespace without URL link | js | 
-|a.navSel             |Current page highlight                         |js    | +| a.nodeUrl | Page | js | 
-|a.indexmenu_idx_head |link style of a namespace with URL (headpage)  |nojs  | +| a.nodeSel | Previous selected page or headpage highlight | js | 
-|a.indexmenu_idx      |link style of a namespace without URL          |nojs  | +| a.navSel | Current page highlight | js | 
-|.indexmenu_arrow     |The scrolling arrow area                       |js    | +| a.indexmenu_idx_head | link style of a namespace with URL (headpage) | nojs | 
-|.indexmenu_toc       |The toc-preview area                           |js    |+| a.indexmenu_idx | link style of a namespace without URL | nojs | 
 +| .indexmenu_arrow | The scrolling arrow area | js | 
 +| .indexmenu_toc | The toc-preview area | js |
  
  
行 469: 行 522:
  
 FIXME check if this example is still up-to-date. For example you could add for the 'thread' theme: FIXME check if this example is still up-to-date. For example you could add for the 'thread' theme:
-<code css lib/plugins/indexmenu/images/thread/style.css>+ 
 +```css lib/plugins/indexmenu/images/thread/style.css
 /*Custom style for the thread theme*/ /*Custom style for the thread theme*/
  
行 480: 行 534:
   color: #fff   color: #fff
 } }
-</code>+``` 
  
 Existing example for 'human.png' theme: `[style.css](https://github.com/samuelet/indexmenu/blob/master/images/human.png/style.css)`. Existing example for 'human.png' theme: `[style.css](https://github.com/samuelet/indexmenu/blob/master/images/human.png/style.css)`.
行 489: 行 544:
 # FAQ and Notes # FAQ and Notes
 ### The tree is not working as expected ### The tree is not working as expected
-  * If you installed for the first time the indexmenu plugin or upgraded it from a previous release, it could be merely a cache issue. Example of symptoms are: tree is not displayed (or a static DokuWiki index is displayed in its place), context menu is not working, any new release feature reported in the [changelog](.indexmenu#changelog) is working.\\ Try to follow instructions to purge cache described in the [The tree is not displayed](.indexmenu#The tree is not displayed) section and retry to display it. +  * If you installed for the first time the indexmenu plugin or upgraded it from a previous release, it could be merely a cache issue. Example of symptoms are: tree is not displayed (or a static DokuWiki index is displayed in its place), context menu is not working, any new release feature reported in the [changelog](.indexmenu#changelog) is working.\ 
-  * When an updated indexmenu plugin fails in a _2013-05-10 "Weatherwax" release_ and later:\\ Please check whether all plugins and your theme don't use the old javascript functions. Since the Weatherwax release, these deprecated functions are missing (some plugins still require an update) and will break the javascript rendering.\\ Check for errors:\\ - in console of browser e.g. as part of the Developer toolbar\\ - by disabling all plugins and enabling one by one+ Try to follow instructions to purge cache described in the [The tree is not displayed](.indexmenu#The tree is not displayed) section and retry to display it. 
 +  * When an updated indexmenu plugin fails in a _2013-05-10 "Weatherwax" release_ and later:\ 
 + Please check whether all plugins and your theme don't use the old javascript functions. Since the Weatherwax release, these deprecated functions are missing (some plugins still require an update) and will break the javascript rendering.\ 
 + Check for errors:\ 
 + - in console of browser e.g. as part of the Developer toolbar\ 
 + - by disabling all plugins and enabling one by one
   * If you think that indexmenu are still not fitting your needs, be sure to using a correct [syntax](.indexmenu#syntax), and read carefully the [configuration](plugin:indexmenu#configuration) instructions. There are a lot of options for this plugin, maybe you missed the good one.   * If you think that indexmenu are still not fitting your needs, be sure to using a correct [syntax](.indexmenu#syntax), and read carefully the [configuration](plugin:indexmenu#configuration) instructions. There are a lot of options for this plugin, maybe you missed the good one.
   * You are sure that the syntax is correct. Perhaps you missed something in this [FAQ and Notes](.indexmenu#FAQ and Notes) section.   * You are sure that the syntax is correct. Perhaps you missed something in this [FAQ and Notes](.indexmenu#FAQ and Notes) section.
行 503: 行 563:
   - To have used a correct [syntax](.:indexmenu#syntax).   - To have used a correct [syntax](.:indexmenu#syntax).
   - To have purged your browser cache. Use `Ctrl + R` or `Ctrl + F5`    - To have purged your browser cache. Use `Ctrl + R` or `Ctrl + F5` 
-  - To have purged server cache following the [purging_the_cache](:caching#purging_the_cache) instructions.:!: This is an important step.+  - To have purged server cache following the [purging_the_cache](caching#purging_the_cache) instructions.:!: This is an important step.
   - To have purged CSS and JavaScript as cached by DokuWiki. Go to the Configuration Manager and just resave, to refresh this caching.   - To have purged CSS and JavaScript as cached by DokuWiki. Go to the Configuration Manager and just resave, to refresh this caching.
   - When you try the javascript version of the indexmenu and it fails, please disable all the self-installed plugins check if now works. Nextly, you enable the plugins one-by-one to find the bad one.   - When you try the javascript version of the indexmenu and it fails, please disable all the self-installed plugins check if now works. Nextly, you enable the plugins one-by-one to find the bad one.
行 520: 行 580:
 ### Indexmenu ID conflict ### Indexmenu ID conflict
 I have in my sidebar the following code  I have in my sidebar the following code 
-<code>+ 
 +```
 {{indexmenu>..#1| js navbar id#random }} {{indexmenu>..#1| js navbar id#random }}
-</code>+``` 
  
 and I get after saving this message: `Indexmenu ID conflict`. What's wrong? and I get after saving this message: `Indexmenu ID conflict`. What's wrong?
行 533: 行 595:
 > When you have a sidebar defined a sidebar, but it is used as normal page too e.g. an index page, it is recommended to create a separate page for the index page. A separate page prevents displaying same index twice so they can not conflict anymore. The index page may have the same syntax options as the sidebar, but when you use id with a self defined id#identifier, your identifier must be different. > When you have a sidebar defined a sidebar, but it is used as normal page too e.g. an index page, it is recommended to create a separate page for the index page. A separate page prevents displaying same index twice so they can not conflict anymore. The index page may have the same syntax options as the sidebar, but when you use id with a self defined id#identifier, your identifier must be different.
  
->> A workaround to get rid of the warning message, is to use the [Nosidebar plugin](:plugin:nosidebar) to remove the sidebar on the sidebar page.+>> A workaround to get rid of the warning message, is to use the [Nosidebar plugin](plugin:nosidebar) to remove the sidebar on the sidebar page.
  
 ### Can I sort the tree nodes (filename or page heading or creation time)? ### Can I sort the tree nodes (filename or page heading or creation time)?
行 548: 行 610:
 The tree is always immediately updated. So you have not to worry to use %%~~NOCACHE~~%% instruction, it's not useful and slows down the page loading. The tree is always immediately updated. So you have not to worry to use %%~~NOCACHE~~%% instruction, it's not useful and slows down the page loading.
  
-To purge cache either wait for the automatic [purge cache time](config:cachetime) expiration or force it through a [purge=true](:devel:caching#purging_the_cache) request on the page that contains the indexmenu tree.+To purge cache either wait for the automatic [purge cache time](config:cachetime) expiration or force it through a [purge=true](devel:caching#purging_the_cache) request on the page that contains the indexmenu tree.
  
  
行 575: 行 637:
   * **Disabled**: Indexmenu doesn't stop its recursive search and it could show denied namespaces (**NOT** pages).   * **Disabled**: Indexmenu doesn't stop its recursive search and it could show denied namespaces (**NOT** pages).
  
-In both cases, unauthorized pages are never showed. There are also some issues [About empty namespaces](.:indexmenu#About empty namespaces) that should be read.\\ +In both cases, unauthorized pages are never showed. There are also some issues [About empty namespaces](.:indexmenu#About empty namespaces) that should be read.\
 This namespace behaviour in presence of ACLs can not be changed until it's not changed in the DokuWiki core itself. This namespace behaviour in presence of ACLs can not be changed until it's not changed in the DokuWiki core itself.
  
 Example: Example:
  
-<code>+ 
 +```
 +-Mysite         (ns) (allowed) +-Mysite         (ns) (allowed)
  +-private       (ns) (denied)  +-private       (ns) (denied)
行 592: 行 655:
  -start          (page) (allowed)  -start          (page) (allowed)
  -start2         (page) (denied)  -start2         (page) (denied)
-</code>+``` 
  
 **Enabled** will display: **Enabled** will display:
-<code>+ 
 +```
 +-Mysite         (dir) +-Mysite         (dir)
  +-public        (dir)  +-public        (dir)
行 602: 行 667:
    -X           (empty/unauthorized icon **displayed only in case of any sort option**)    -X           (empty/unauthorized icon **displayed only in case of any sort option**)
  -start          (page)  -start          (page)
-</code>+``` 
  
 **Disabled** will display: **Disabled** will display:
-<code>+ 
 +```
 +-Mysite         (dir) +-Mysite         (dir)
  +-private       (dir)  +-private       (dir)
行 615: 行 682:
    -X           (empty/unauthorized icon **displayed only in case of any sort option**)    -X           (empty/unauthorized icon **displayed only in case of any sort option**)
  -start          (page)  -start          (page)
-</code>+``` 
  
  
行 628: 行 696:
 When the `max#nr` option or level of folded nodes are configured and the node has to retrieve its children through the Ajax request, there can appear empty nodes because indexmenu hasn't looked forward and doesn't know yet that the node was empty. When the `max#nr` option or level of folded nodes are configured and the node has to retrieve its children through the Ajax request, there can appear empty nodes because indexmenu hasn't looked forward and doesn't know yet that the node was empty.
  
-**Why do you need a sort option to correctly hide empty namespaces?**\\+**Why do you need a sort option to correctly hide empty namespaces?**\
 When any of the sort options `tsort`, `dsort`, `msort` `nsort` or `hsort` is used indexmenu replaces the faster, but less featured, core DokuWiki search with the slower, but more featured, indexmenu search that filters more empty nodes. When any of the sort options `tsort`, `dsort`, `msort` `nsort` or `hsort` is used indexmenu replaces the faster, but less featured, core DokuWiki search with the slower, but more featured, indexmenu search that filters more empty nodes.
  
-**Why will sneaky_index hide forbidden namespaces**\\+**Why will sneaky_index hide forbidden namespaces**\
 Enabling the `[sneaky_index](config:sneaky_index)` also checks for access to forbidden namespaces, instead of only checking access to pages. This means that it hides deeper allowed pages or namespaces as well. These nodes aren't reachable via the index anymore.. See also [About ACLs](#About ACLs). Enabling the `[sneaky_index](config:sneaky_index)` also checks for access to forbidden namespaces, instead of only checking access to pages. This means that it hides deeper allowed pages or namespaces as well. These nodes aren't reachable via the index anymore.. See also [About ACLs](#About ACLs).
  
  
 ### I'm using "useheading" but the tree displays namespace and page names rather than headings ### I'm using "useheading" but the tree displays namespace and page names rather than headings
-The text used for the nodes in the tree is retrieved from DokuWiki's [metadata](:metadata) store.  DokuWiki uses a background process triggered by a web-bug to updating this metadata.((See [taskrunner](:taskrunner).))  If you added wiki pages/namespaces via the filesystem (rather than creating them in DokuWiki,) and that page/namespace has never been viewed, the metadata will not have been generated.+The text used for the nodes in the tree is retrieved from DokuWiki's [metadata](metadata) store.  DokuWiki uses a background process triggered by a web-bug to updating this metadata.((See [taskrunner](taskrunner).))  If you added wiki pages/namespaces via the filesystem (rather than creating them in DokuWiki,) and that page/namespace has never been viewed, the metadata will not have been generated.
  
  
行 648: 行 716:
  
 # Discussion # Discussion
-Please, use the [discussion](.:indexmenu:discussion) page for feature requests and general discussion.\\ Old discussions are archived in the [olddiscussion](.:indexmenu:olddiscussion) page.+Please, use the [discussion](.:indexmenu:discussion) page for feature requests and general discussion.\ 
 + Old discussions are archived in the [olddiscussion](.:indexmenu:olddiscussion) page.
wiki/插件语法/indexmenu.1791900372.txt.gz · 最后更改: 由 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki