All A's in This Web

These INCLUDEs are used by index pages (eg, EdgeIndex, NodeIndex, ViewIndex). They provide information on, and navigation to, pages of a particular type that are located in the current TWiki web.

All Edges in a Web (edges_of_web)

Screenshot:

mbw_edges_of_web.png

Description:

Used in the EdgeIndex page. For each Edge page, generate a table row.

Code:

%STARTSECTION{"edges_of_web"}%
%~~ SEARCH{"META:FORM{name=\"EdgeForm"  excludetopic="EdgeTemplate, EdgeForm"
~~~ noheader="on" nosearch="on"
~~~ order="formfield(EdgeTitle)"
~~~ format="|
~~~ [[$topic][$formfield(EdgeTitle)]] |
~~~ $formfield(EdgeSummary) |
~~~ "
~~~ }%
%ENDSECTION{"edges_of_web"}%

All Nodes in a Web (nodes_of_web)

Screenshot:

mbw_nodes_of_web.png

Description:

Used in the NodeIndex page. For each Node page, generate a table row.

Code:

%STARTSECTION{"nodes_of_web"}%
%~~ SEARCH{"META:FORM{name=\"NodeForm"  excludetopic="NodeTemplate, NodeForm"
~~~ noheader="on" nosearch="on"
~~~ order="formfield(NodeTitle)"
~~~ format="|
~~~ [[$topic][$formfield(NodeTitle)]] |
~~~ $formfield(NodeSummary) |
~~~ "
~~~ }%

---+++ Nonexistent Nodes (if any)

<!-- We don't want to see this table, just use it...
%INCLUDE{"NodeNames"}%
-->

%CALC{"$SET(VAR, $LIST(R3:C1..R$ROW(0):C1))"}%
<ul>
%~~ FOREACH{"name" in="%CALC{"$GET(VAR)"}%"}%
~~~ $percntCALC{ $SET(FOUND, $percntSEARCH{"META:FIELD.*name=\"NodeName\".*value=\"$name\""
~~~   topic="N_*" type="regex" nonoise="on" separator=", " format="$topic" }$percnt ) }$percnt
~~~ $percntCALC{ $IF($EXACT($GET(FOUND),),<li>$name,) }$percnt %NEXT{"name"}%
</ul>

%ENDSECTION{"nodes_of_web"}%

All Views in a Web (views_of_web)

Screenshot:

mbw_views_of_web.png

Description:

Used in the ViewIndex page. For each View page, generate a table row.

Code:

%STARTSECTION{"views_of_web"}%
%~~ SEARCH{"META:FORM{name=\"ViewForm"  excludetopic="ViewTemplate, ViewForm"
~~~ noheader="on" nosearch="on"
~~~ order="formfield(ViewTitle)"
~~~ format="|
~~~ [[$topic][$formfield(ViewTitle)]] |
~~~ $formfield(ViewSummary) |
~~~ "
~~~ }%

---+++ Nonexistent Views (if any)

<!-- We don't want to see this table, just use it...
%INCLUDE{"ViewNames"}%
-->

%CALC{"$SET(VAR, $LIST(R3:C1..R$ROW(0):C1))"}%
<ul>
%~~ FOREACH{"name" in="%CALC{"$GET(VAR)"}%"}%
~~~ $percntCALC{ $SET(FOUND, $percntSEARCH{"META:FIELD.*name=\"ViewName\".*value=\"$name\""
~~~   topic="V_*" type="regex" nonoise="on" separator=", " format="$topic" }$percnt ) }$percnt
~~~ $percntCALC{ $IF($EXACT($GET(FOUND),),<li>$name,) }$percnt %NEXT{"name"}%
</ul>

%ENDSECTION{"views_of_web"}%


This wiki page is maintained by Rich Morin, an independent consultant specializing in software design, development, and documentation. Please feel free to email comments, inquiries, suggestions, etc!

This topic: Projects/MBW/MBW_e > MbwAdmin > MbwIncludes > MbwIncludesAW
Topic revision: 01 Sep 2008, RichMorin
This site is powered by Foswiki Copyright © by the contributing authors. All material on this wiki is the property of the contributing authors.
Foswiki version v2.1.6, Release Foswiki-2.1.6, Plugin API version 2.4
Ideas, requests, problems regarding CFCL Wiki? Send us email