[dokuwiki] Re: How to number headlines ?

  • From: Chris Smith <chris@xxxxxxxxxxxxx>
  • To: dokuwiki@xxxxxxxxxxxxx
  • Date: Wed, 05 Apr 2006 21:06:04 +0100

Hi,

I have a rough and ready plugin to do this.

It needs modifications to parts of the parser to work properly.
(1) Changes to header / section handling. I reckon they are improvements over the current methods so I'll package them up in a patch for Andi to look at.


(2) Modifications to block_handler. These are more complex (refer other note). For now my rough and ready version will result in xhtml with one unmatched </p> at the end of every set of xhtml prepared by the renderer.

For now, I have used ~~OH:<depth>|<pattern>~~ pattern syntax.

Anyways, feel free to take a look at it and extend it or do what you like with it.
ideas would be:
- config settings via the config plugin
- better pattern handling
- Anika's ===== ## heading ===== syntax


Code can be seen at:
http://wiki.jalakai.co.uk/dokuwiki/doku.php/tutorial/header

Test page is:
http://wiki.jalakai.co.uk/dokuwiki/doku.php/test/header

I'll try and get around to putting something up on splitbrain.

Cheers,

Chris
--
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Other related posts: