Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The documentation does not define "subkey" or provide enough examples #6

Open
winakeytoheaven opened this issue May 21, 2020 · 0 comments

Comments

@winakeytoheaven
Copy link

I needed to set the value of the "abstract" meta property and reference it from within the DIR plugin, something that seemed workable. I spent almost all day researching Dokuwiki's meta-data structures, experimenting with plugin-meta syntax and single-stepping through the plugin-meta code to finally discover that [1] the "abstract" meta-property is a "subkey" of the "description" meta-property and [2] the plugin-meta syntax for subkeys is untouched by its documentation. I finally discovered the proper syntax and was able to make the META and DIR plugins work together as desired. Whew.

I'm not complaining about the time because it was a geeky challenge and I learned a LOT, but this plugin's documentation should be more complete because not everybody has the time, developer background or software tools required to do what I did. I created my own account on dokuwiki.org thinking I could update the plugin-meta documentation with what I learned, but getting normal dokuwiki.org credentials doesn't give editing rights. Sigh.

Other points:

  • The code which parses the keys, subkeys and values is a bit brittle. It doesn't recognize and render a syntax error involving a subkey, which provokes a fatal PHP error in the bowels of the Dokuwiki renderer and instantly leaves the site inoperable until you get into the server's backend and remove the offending syntax from the page content. This is an inconvenient way to discover what the proper syntax should be.
  • The so-called description of a page is internally its abstract, and the abstract is a subkey of description in the minds of Dokuwiki and plugin-meta. By default, abstract is preloaded with the first 250 characters of the page content after every edit UNLESS plugin-meta has declared another value (which is what I was trying to do).
  • The proper plugin-meta syntax for this specific value is description abstract = [your-text] (not including the preceding "&" if the line is not the first in the ~~META declaration).

I would be happy to augment the documentation myself if I had a way to do that, obviously in collaboration with the plugin author/maintainer. I envision adding a table of examples to document the full spectrum of all the settable metadata properties (which is a small subset of all the properties which actually exist within Dokuwiki).

I wish I had time, now that I know more about how this plugin works, to offer some help with the code. That's another issue for another day. Sigh.

I like this plugin and I'm very happy it exists. Let me know how I can be involved in at least improving the documentation. Thanks.

@winakeytoheaven winakeytoheaven changed the title The documentation does not define "subkey" or give useful examples The documentation does not define "subkey" or provide enough examples May 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant