DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:mdpage

Markdown Page Plugin

Compatible with DokuWiki

  • 2020-07-29 "Hogfather" yes
  • 2018-04-22 "Greebo" yes
  • 2017-02-19 "Frusterick Manners" unknown
  • 2016-06-26 "Elenor Of Tsort" unknown

plugin Show markdown block as a DokuWiki content

Last updated on
2021-01-09
Provides
Syntax
Repository
Source
Conflicts with
commonmark, markdownextra

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

A simple block:

<markdown>
# Header

simple paragraph: *emph* **strong** `mono`.

> quote

[link](https://www.dokuwiki.org)
</markdown>

Configuration and Settings

name description
flavor Markdown Flavor
markdown_default You can use plain Markdown to write all pages without any special words by this option. :!: This is experimental feature and will change the specification.

Syntax

Basic syntax:

<markdown>some markdown text</markdown>

This plugin supports three flavors:

This plugin supports internal links:

<markdown>
[internal link](:start)
[interwiki link](doku>plugin:mdpage)

![internal image](:wiki:dokuwiki-128.png)
</markdown>

Markdown Defaulting (Experimental)

If you enable markdown_default, you often use Markdown syntax without any tags. However, need a tag if you want to use DokuWiki syntax in Markdown as follows:

<!DOCTYPE markdown>

# Header

any Markdown contents: **Bold Text**, `Inline Code`

<script type="text/x-dokuwiki>
any DokuWiki content: **Bold Text**, <del>Strike-through Text</del>, ''Inline Code''
</script>

any Markdown contents: **Bold Text**, `Inline Code`

FAQ

  • Q: I cannot use inline HTML. Is this plugin supported HTML?
    • A: Yes. Please enable htmlok and then retry.
  • Q: I cannot use footnotes with Markdown Extra. Is this plugin supported Markdown Extra?
    • A: This plugin is not support full Markdown Extra flavor. See Issue #74.

Development

Change Log

Full releases: https://github.com/mizunashi-mana/dokuwiki-plugin-mdpage/releases

  • Release v2.2.0 (2021-01-09 08:47)
    Support links with titles: Fix #35
  • Release v2.1.0 (2020-12-20 09:53)
    More support markdown defaulting: Support #71
  • Release v2.0.0 (2020-09-13 19:33)
    Add Markdown defaulting switch (experimental feature). Support #66 Fix #64
  • Release v1.1.3 (2020-09-13 08:56)
    Update dependencies for Hogfather
  • Release v1.1.2 (2020-06-14 06:02)
    Include ctype polyfills. Fix #57

Known Issues and Wishes

When you find a bug or want any features and it is not appeared on this section, please make a new issue.

  • Incompatibility with Emoji plugin
    This is a bug report. Name Value dokuWiki version 2020-07-29 "Hogfather" OS Docker image linuxserver/dokuwiki on Oracle Linux Host Expect behavior: The Emoji plugin and mdpage don't seem to play well together. Not sure wether this is an Emoji issue or an mdpage issue though. Any Emoji inserted within the tags such as <markdown> :warning: </markdown> will display the litteral text instead of the emoji Actual behavior: Litteral text is displayed instead of the emoji icon Details:
  • checkboxes are not rendered
    This is a bug report. Disclaimer: I think this is a bug report. But there is the possibility, that this feature is not supposed to work anyway. I just don't know. If this feature is not supposed to work, then I will create a feature wish out of it Name Value DokuWiki Version Release 2020-07-29 "Hogfather" PHP Version 7.4.20 OS CentOS 7.9.2009 Web Server Apache 2.4.6 Markdown Page Plugin 2021-01-09 Expect behavior: The following markup code: ====== mdpage plugin test ====== <markdown> # title is working, but - [ ] checkboxes - [ ] not, no * [ ] matter how * [ ] I write - [ ] them - [x] ;-) </markdown> is expected to render as checkboxes as shown here (same MarkDown code as rendered in GitLab): Actual behavior: Checkboxes are not shown: Details: The MarkDown mode is set to github-flavored
  • Wrong install
    After install plugin on work wiki - my wiki dont work and say Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 7.1.0".
  • Improve DokuWiki integration with Markdown defaulting
    This is a feature request. Specification Excepted to use other plugins in mdpage without <script type="text/x-dokuwiki"> with markdown_default=1. Motivations Related issue: #71 I'm finding a way to let Markdown and DokuWiki's original syntax works together, like markdowku did. But markdowku's Markdown parser not working as expected and too hard to fix. I hope I can use plugins like https://www.dokuwiki.org/plugin:tag in mdpage without lengthy <!doctype markdown> with markdown_default = 1, I tried: Rendering DokuWiki before or after mdpage is impossible, both DokuWiki and mdpage will add <p></p> to all paragraphs which another parser will ignore all code wrapped by <p></p>. And it's hard to close this feature in both two parsers. Turning down the getSort of mdpage is useless because DokuWiki will combine all patterns into a large regexp with |. Let mdpage rendering syntaxs added by addSpecialPattern as I did in #71. This way is possible but toooooo hard to implement and bad for following DokuWiki upgrade.
  • markdown-extra flavor not fully supported?
    Hi!, it seems that markdown-extra is not fully supported. Specifically, the footnotes feature doesn't work (https://michelf.ca/projects/php-markdown/extra/#footnotes). It would be possible to fix this? Thanks!
  • Editing a section edits the entire page, but cuts off the last 2 characters.
    This is a bug report. Name Value DokuWiki Version 2020-07-29 "Hogfather" PHP Version 7.4.6 OS Darwin Web Server Apache/2.4.46 (Unix) PHP/7.4.6 Details: The "edit" button next to each header doesn't seem to respect markdown sections properly. If I click on one in a markdown block, it starts editing the entire page, but it cuts off the last 2 characters. In my case, this usually breaks the </markdown> tag by replacing it with </markdow, but it's always just the last two characters.
  • mdpage plugin doesn't work with farms
    This is a bug report. Name Value DokuWiki Version Release 2020-07-29 "Hogfather" PHP Version PHP Version 7.3.5 OS Debian 4.19.132-1 (2020-07-24) x86_64 GNU/Linux Web Server Apache/2.4.25 (Debian) Details: When installing the mdpage plugin in a Dokuwiki farm, Dokuwiki becomes inoperable because the condition below doesn't meet, even though the file exists, there should be another way to validate it in a farm environment. https://github.com/mizunashi-mana/dokuwiki-plugin-mdpage/blob/8d8ade76b71acfced603580f7ad4cbe9c76d5e08/src/bootstrap.php#L7-L10 Farm directory structure: The error I got is: I'm not sure if the src/bootstrap.php is required at all within this plugin, the function includeIfExists isn't being called outside this file.
  • Incorrect style nesting on headings
    This is a bug report. Name Value DokuWiki Version Release 2018-04-22b "Greebo" PHP Version 7.3.10 OS Linux Web Server Apache/2.4.41 (Unix) OpenSSL/1.1.0l PHP/7.3.10 Docker image bitnami/dokuwiki Details: Given the following simple page code: <markdown> # This `is` a `test` This is text </markdown> Instead of the expected heading: This is a test It renders: This a Thanks!
plugin/mdpage.txt · Last modified: 2021-01-09 09:02 by mizunashi-mana

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