<span class='foswikiAlert'> IF{ Applications="1" "'<param name=" data="1" default="1" }: Syntax error in ''<param name=' at ''<param name=' %DBCALL{"Applications.RenderWikiTopicView" OBJECT="<param name=

Documentation

This function displays part of the hierarchy a topic is situated in. It tries to provide a sense of "location" for the topic based on the way it is classified.

TODO: what do we display for topics that are not categorized?

Implementation

%STARTINCLUDE%<div class="clsSideBar clsBrowser" id="clsSideBarCategoryBrowser" style="display:none">
%HIERARCHY{
  web="%BASEWEB%"
  open="$percntIF{
      \"$percntDISTANCE{
          from=\"$name\"
          to=\"%URLPARAM{"catname" default="%BASETOPIC%"}%\"
          undef=\"-1\"
        }$percnt >= 0\"
      then=\"$name\" 
    }$percnt, %TOP{default="TopCategory"}%"
  placeholder="<li><span class='placeholder'>&nbsp;</span></li>"
  top="%TOP{default="TopCategory"}%"
  exclude="%TOP{default="TopCategory"}%"
  header="<ul>"
  footer="</ul>"
  format="<li id=\"$name\" class=\"$percntIF{\"'$subcats'!='0'\" then=\"hasChildren\"}$percnt\">
    <a style='background-image:url($icon);' class='clsCategoryLink $percntIF{
      \"( $percntISA{
            \"%BASETOPIC%\"
            cat=\"$name\"
          }$percnt = 1 
          and
          $percntDISTANCE{
            from=\"$name\"
            to=\"%BASETOPIC%\"
            undef=\"-1\"
          }$percnt = 1
        ) or $percntDISTANCE{
               from=\"$name\"
               to=\"%URLPARAM{"catname" default="%BASETOPIC%"}%\"
               undef=\"-1\"
             }$percnt = 0
      \"
      then=\"current\"
    }$percnt' href=\"$url\" title=\"$percntENCODE{$summary}$percnt\"><noautolink>$title</noautolink>
    </a>$children</li>"
}%</div>%JQREQUIRE{"treeview"}%
%ADDTOZONE{"script"
   text="<script type='text/javascript' src='%PUBURLPATH%/Applications/ClassificationApp/RenderSideBar/render-sidebar.js'></script>"
   id="RENDERSIDEBAR::JS"
   requires="JQUERYPLUGIN"
}%%STOPINCLUDE%

Test

Calls to 'RenderSideBar'

Copyright

© 2006-2019 Michael Daum http://michaeldaumconsulting.com

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.
Topic attachments
ISorted ascending Attachment Action Size Date Who Comment
render-sidebar.jsjs render-sidebar.js manage 820 bytes 23 Jan 2017 - 12:25 ProjectContributor Generated by AttachContentPlugin
Warning: Can't find topic Applications/ClassificationApp.WebLeftBarExample

This site is powered by FoswikiCopyright by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding DAMASK? Send feedback
§ Imprint § Data Protection