none
[openafs-wiki.git] / TWiki / TWikiVariables.mdwn
index 4e7a965..d04bd6f 100644 (file)
@@ -1,5 +1,21 @@
+<div>
+  <ul>
+    <li><a href="#TWiki Variables"> TWiki Variables</a><ul>
+        <li><a href="#About Variables"> About Variables</a></li>
+        <li><a href="#Predefined Variables"> Predefined Variables</a></li>
+        <li><a href="#Preferences Variables"> Preferences Variables</a></li>
+        <li><a href="#Setting and Creating New Prefere"> Setting and Creating New Preferences</a></li>
+      </ul>
+    </li>
+  </ul>
+</div>
+
 ## <a name="TWiki Variables"></a> TWiki Variables
 
+### <a name="About Variables"></a> About Variables
+
+**_Include/write if not found elsewhere._**
+
 ### <a name="Predefined Variables"></a> Predefined Variables
 
 %WIKITOOLNAME% expands the following variables enclosed in % percent signs:
           <td> 2 digit year </td>
           <td> 99 </td>
         </tr>
-      </table> Variables can be shortened to 3 characters. Example: <br /><code>%GMTIME{"$day $month, $year - $hour:$min:$sec"}%</code> is <br /><b>29 Jun, 2010 - 15:27:16</b></td>
+      </table> Variables can be shortened to 3 characters. Example: <br /><code>%GMTIME{"$day $month, $year - $hour:$min:$sec"}%</code> is <br /><b>29 Jun, 2010 - 15:27:35</b></td>
   </tr>
   <tr>
     <td><code>%SERVERTIME%</code></td>
   </tr>
   <tr>
     <td><code>%TOC%</code></td>
-    <td> Table of Content of current topic. </td>
+    <td> Table of Contents of current topic. </td>
   </tr>
   <tr>
     <td><code>%TOC{"SomeTopic" ...}%</code></td>
-    <td> Table of Content. Shows a TOC that is generated automatically based on headings of a topic. Headings in [[Main/WikiSyntax]] (<code>"---++ text"</code>) and HTML (<code>"&lt;h2&gt;text&lt;h2&gt;"</code>) are taken into account. (But not <code>"&lt;H2&gt;text&lt;H2&gt;"</code>, which can be used to exclude a heading from the TOC.) Parameters are topic name, web and depth: <table border="1" cellpadding="0" cellspacing="0">
+    <td> Table of Contents. Shows a TOC that is generated automatically based on headings of a topic. Headings in [[Main/WikiSyntax]] (<code>"---++ text"</code>) and HTML (<code>"&lt;h2&gt;text&lt;h2&gt;"</code>) are taken into account. (But not <code>"&lt;H2&gt;text&lt;/H2&gt;"</code>, which can be used to exclude a heading from the TOC.) Parameters are topic name, web and depth: <table border="1" cellpadding="0" cellspacing="0">
         <tr>
           <th bgcolor="#99CCCC"><strong> Parameter: </strong></th>
           <th bgcolor="#99CCCC"><strong> Description: </strong></th>
@@ -558,11 +574,11 @@ Additional variables are defined in the preferences ( site-level ( **_SL_** ) in
   </tr>
 </table>
 
-**_Notes:_**
+### <a name="Setting and Creating New Prefere"></a> Setting and Creating New Preferences
 
-- Preferences variables ( on site-level, web-level and user level ) are defined by bullet lines with this syntax:
-  - `Set VARIABLENAME = value`
-- Additional preferences variables can be defined on all three level as needed. Example:
-  - `Set MYLOGO = %PUBURLPATH%/%MAINWEB%/LogoTopic/logo.gif`
+- The syntax for Preferences variables is the same anywhere in TWiki. In Edit mode, from the start of a new line: <br />[6 spaces] \* [space] Set [space] VARIABLENAME [space] = [value] <br />**_Example:_**
+  - <code>**Set VARIABLENAME = value**</code>
+- You can add your own preference variables for an entire site, a single web, or a single topic, using the standard syntax. Whatever you include in your variable will be expanded on display, and treated exactly as if it had been written out. So you can place formatted text, page links, images.<br />**_Example:_** To place a logo anywhere in a web by typing <code>**%MYLOGO%**</code>, define the variable in the web's [[WebPreferences]] topic, like this (in this case, you also have to upload <code>**logo.gif**</code> to the same directory):
+  - <code>**Set MYLOGO = %PUBURLPATH%/%MAINWEB%/LogoTopic/logo.gif**</code>
 
--- [[PeterThoeny]] - 23 Jul 2001 <br />
+-- [[MikeMannix]] - 26 Aug 2001 <br />