Question
Some time ago I modified my copy of TWiki.pm getRenderedVersion() to add some new list syntax. Specifically, 3*n spaces followed by x, o, or p result in <li class=checked>, <li class=unchecked>, and <li class=partchecked> respectively. My style sheet renders these with gifs that look like a checkbox, an unchecked checkbox, and a greyed-out checked checkbox respectively. Handy for to-do lists.
But I want to move this code into a plugin (specifically the
StylePlugin) so that I can more readily update the TWiki code as new releases are made. But I'm
really struggling with this. The problem I'm up against is that the list-rendering code in getRenderedVersion has some smarts about knowing when to insert <ul> or <ol> tags. I'm just not seeing how to achieve the same thing from a plugin.
Can someone help me?
- TWiki version: Dec 2001
- Perl version: 5.6 (?)
- Web server & version: apache 1.37
- Server OS: BSD
- Web browser & version:
- Client OS:
--
DaleBrayden - 03 Mar 2003
Answer