DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:linkpagechild

linkpagechild Plugin

Compatible with DokuWiki

  • 2018-04-22 "Greebo" yes
  • 2017-02-19 "Frusterick Manners" unknown
  • 2016-06-26 "Elenor Of Tsort" unknown
  • 2015-08-10 "Detritus" unknown

plugin Links & media inclusions whose target path starts with '::' resolve to the namespace with the name of the current page, under the current namespace.

Last updated on
2018-08-05
Provides
Syntax
Repository
Source

Tagged with links, media, syntax

linkpagechild is a syntax plugin that adds a small behavior to how paths in page links and media links are interpreted, interpreting “::” at the start of the path as “a sub-namespace under the current namespace, named for the current page”. This makes it easy to lay out your attachments like Zim Desktop Wiki does — attachments are in a folder named for the page containing them

Installation

Install the plugin using the Plugin Manager and the download URL above, which points to latest version of the plugin. Refer to Plugins on how to install plugins manually.

Examples/Usage

On a page called “:blog:2018-08:my-cat-did-something-funny”, the following media link

{{::cat-picture.jpg}}

would resolve to the media attachment “:blog:2018-08:my-cat-did-something-funny:cat-picture.jpg”.

Likewise, on a page called “:howto” the following page link

[[::capture-the-best-cat-picture]]

would resolve to the page “:howto:capture-the-best-cat-picture”.

Syntax

This plugin augments the behavior of standard page links and media links as described in the DokuWiki syntax man page. Follow the syntax explained there, and use the “::” prefix as a shortcut for “a sub-namespace under the current namespace, named for the current page”.

Configuration and Settings

This plugin does not have any configurable behavior.

Development

Change Log

  • 2018-08-05
    • Initial release

Known Bugs and Issues

Please see the public issue tracker.

FAQ

(No FAQs yet.)

Discussion

Currently leading search and discussion on how to link to a media in relativ way by using a other media (image) as teaser/linkdisplay here [(for case) Solved] Is there a syntax to directly link to media-files in "same" ns?, my person wonders if the plugin allows a “trick” or could be enriched by this missing possibility for links on DW someting like [[{{::mediafile.xyz}}|{{any_image}}]] or a resolve that adds the _media-path + path into this image link url, maybe by something like :::, [[:::mediafile.xyz|{{any_image}}]]. (me it be pardoned if using this place here in probably not welcome way). — Samana JohannSamana Johann

2018-10-11 02:12
plugin/linkpagechild.txt · Last modified: 2018-10-11 02:38 by Samana Johann