commit 9e5bf4b8abeb14a167337c6ea252bf1f55470489 parent a8990a454ebd93711bb160dde5d12bc021a2047b Author: uriel@soma <unknown> Date: Tue, 3 Mar 2009 12:32:03 +0000 New link_bar handler to be used in sidebars. Diffstat:
M | bin/corehandlers.rc | | | 12 | ++++++++++++ |
1 file changed, 12 insertions(+), 0 deletions(-)
diff --git a/bin/corehandlers.rc b/bin/corehandlers.rc @@ -31,6 +31,18 @@ fn nav_tree { END { p(lNF, 0, "</ul>") }' } +fn link_bar { + if(~ $1 -t) { + echo '<p class="sideBarTitle">'$2'</p>' + shift; shift + } + echo '<ul>' + while(! ~ $#* 0) { + echo '<li><a href="'$2'">- '$1'</a></li>' + shift; shift + } + echo '</ul>' +} fn md_handler { $formatter < $1 }