Categorization and folksomony application

Function: RenderCategoryBrowser

Renders a hierarchical browser for categories

Documentation

Parameters
  • TOP: node from where to start the category, defaults to 'TopCategory'
  • EXCLUDE: filter to exclude categories
  • THEWEB: where to search for categories, defaults to BASEWEB
  • UNIQUE: "on" or "off"

Css

Implementation

%STARTINCLUDE%<div class="clsBrowser jqTreeview %IFDEFINED{"%UNIQUE%" as="off" then=" " else=" unique"}%">
~~~ <noautolink>
%~~ HIERARCHY{
~~~   web="%IFDEFINED{"%THEWEB%" then="$test" else="%BASEWEB%"}%"
~~~   %IFDEFINED{"%TOP%" then="top=\"$test\"" glue="off"}%
~~~   exclude="%IFDEFINED{"%EXCLUDE%" then="$test" else="TopCategory"}%"
~~~   header="<ul>"
~~~   footer="</ul>"
~~~   format="<li class=\"
~~~     $percntIFDEFINED{
~~~       \"$percntSUBSUMES{\"$name\" web=\"%BASEWEB%\" cat=\"%BASETOPIC%\" }$percnt\" 
~~~       as=\"1\" 
~~~       then=\"open\"
~~~       else=\"closed\"
~~~     }$percnt\">
~~~     <a href=\"$url\" 
~~~          $percntIFDEFINED{\"%BASETOPIC%\" as=\"$name\" glue=\"off\"
~~~            then=\"class=\\"twikiCurrentTopicLink\\"\"
~~~          }$percnt
~~~          title=\"$summary\">
*~~         $title</a>
~~~       $percntIFDEFINED{\"$cyclic\" as=\"1\" 
~~~         then=\" <span class='twikiAlert'>C</span>\"
~~~       }$percnt
~~~       $percntIFDEFINED{\"$count \" as=\"0 \" then=\" \" else=\" ($count)\"}$percnt
~~~       $children</li>"
~~~ }%
~~~ </noautolink>
~~~ </div>
~~~ %STOPINCLUDE%

Test

Calls to 'RenderCategoryBrowser'

Copyright

© 2007 Michael Daum http://wikiring.de

This file is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. For more details read the LICENSE.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY, to the extent permitted by law; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Applications.ApplicationTopic
TopicType: DocuTopic, TopicFunction
Summary: Renders a hierarchical browser for categories
TWikiApplication: ClassificationApp
r0 - 29 Jul 2007 - 12:12:40 - TWikiContributor
© giant orange extension cord that reeks hip-hop, funk & soul