1 <a name="VarTOPICLIST"></a>
3 ### <a name="TOPICLIST{"format"} -- topic ind"></a> TOPICLIST\{"format"\} -- topic index of a web
5 - List of all topics in a web. The "format" defines the format of one topic item. It may include variables: The `$name` variable gets expanded to the topic name, `$qname` to double quoted name, `$marker` to `marker` parameter where topic matches `selection`, and `$web` to the name of the web.
6 - Syntax: `%TOPICLIST{"format" ...}%`
7 - Supported parameters: <table border="1" cellpadding="0" cellspacing="0">
9 <th bgcolor="#99CCCC"><strong> Parameter: </strong></th>
10 <th bgcolor="#99CCCC"><strong> Description: </strong></th>
11 <th bgcolor="#99CCCC"><strong> Default: </strong></th>
14 <td><code>"format"</code></td>
15 <td> Format of one line, may include <code>$web</code> (name of web), <code>$name</code> (name of the topic), <code>$qname</code> (name of topic in double quotes), <code>$marker</code> (which expands to <code>marker</code> for the item matching <code>selection</code> only) </td>
16 <td><code>"$name"</code></td>
19 <td><code>format="format"</code></td>
20 <td> (Alternative to above) </td>
21 <td><code>"$name"</code></td>
24 <td><code>separator=", "</code></td>
25 <td> line separator </td>
26 <td><code>"$n"</code> (new line) </td>
29 <td><code>marker="selected"</code></td>
30 <td> Text for <code>$marker</code> if the item matches <code>selection</code></td>
31 <td><code>"selected"</code></td>
34 <td><code>selection="TopicA, TopicB"</code></td>
35 <td> Current value to be selected in list </td>
36 <td><code>(none)</code></td>
39 <td><code>web="Name"</code></td>
40 <td> Name of web </td>
41 <td> Current web </td>
44 - Example: `%TOPICLIST{" * $web.$name"}%` creates a bullet list of all topics
45 - Example: `%TOPICLIST{separator=", "}%` creates a comma separated list of all topics
46 - Example: `%TOPICLIST{" <option>$name</option>"}%` creates an option list (for drop down menus)
47 - Example: `<select>%TOPICLIST{" <option $marker value='$name'>$name</option>" separator=" " selection="%TOPIC%"}%</select>` creates an option list of web topics with the current topic selected
48 - Related: [[SEARCH|Main/WebHome#VarSEARCH]], [[WEBLIST|Main/WebHome#VarWEBLIST]]