buildrelease
[openafs-wiki.git] / TWiki / VarMETASEARCH.mdwn
diff --git a/TWiki/VarMETASEARCH.mdwn b/TWiki/VarMETASEARCH.mdwn
new file mode 100644 (file)
index 0000000..2feb968
--- /dev/null
@@ -0,0 +1,57 @@
+<a name="VarMETASEARCH"></a>
+
+### <a name="METASEARCH -- special search of"></a><a name="METASEARCH -- special search of "></a> METASEARCH -- special search of meta data
+
+- Syntax: `%METASEARCH{...}%`
+- Supported parameters: <table border="1" cellpadding="0" cellspacing="0">
+  <tr>
+    <th bgcolor="#99CCCC"><strong> Parameter: </strong></th>
+    <th bgcolor="#99CCCC"><strong> Description: </strong></th>
+    <th bgcolor="#99CCCC"><strong> Default: </strong></th>
+  </tr>
+  <tr>
+    <td><code>type="topicmoved"</code></td>
+    <td> What sort of search is required? <br /><code>"topicmoved"</code> if search for a topic that may have been moved <br /><code>"parent"</code> if searching for topics that have a specific parent i.e. its children <br /><code>"field"</code> if searching for topics that have a particular form field value (use the <code>name</code> and <code>value</code> parameters to specify which field to search) </td>
+    <td> required </td>
+  </tr>
+  <tr>
+    <td><code>web="%WEB%"</code></td>
+    <td> Wiki web to search: A web, a list of webs separated by whitespace, or <code>all</code> webs. </td>
+    <td> current web </td>
+  </tr>
+  <tr>
+    <td><code>topic="%TOPIC%"</code></td>
+    <td> The topic the search relates to, for <code>topicmoved</code> and <code>parent</code> searches </td>
+    <td> current topic </td>
+  </tr>
+  <tr>
+    <td><code>name</code></td>
+    <td> form field to search, for <code>field</code> type searches. May be a regular expression (see [[Main/WebHome#VarSEARCH]]). </td>
+    <td>   </td>
+  </tr>
+  <tr>
+    <td><code>value</code></td>
+    <td> form field value, for <code>field</code> type searches. May be a regular expression (see [[Main/WebHome#VarSEARCH]]). </td>
+    <td>   </td>
+  </tr>
+  <tr>
+    <td><code>title="Title"</code></td>
+    <td> Text that is prefixed to any search results </td>
+    <td> empty </td>
+  </tr>
+  <tr>
+    <td><code>default="none"</code></td>
+    <td> Default text shown if no search hit </td>
+    <td> empty </td>
+  </tr>
+</table>
+- Example: `%METASEARCH{type="topicmoved" web="%WEB%" topic="%TOPIC%" title="This topic used to exist and was moved to: "}%`
+- Example: You may want to use this in [[WebTopicViewTemplate]] and [[WebTopicNonWikiTemplate]]:<br />`%METASEARCH{type="parent" web="%WEB%" topic="%TOPIC%" title="Children: "}%`
+- Example: `%METASEARCH{type="field" name="Country" value="China"}%`
+- Related: [[SEARCH|Main/WebHome#VarSEARCH]], [[META|Main/WebHome#VarMETA]]
+
+**_Related Topics:_** [[UserDocumentationCategory]]
+
+**_Note:_** This topic is included by [[TWikiVariables]]
+
+----