<div>
<ul>
<li><a href="#TWiki Variables"> TWiki Variables</a><ul>
+ <li><a href="#Overview"> Overview</a></li>
<li><a href="#Predefined Variables"> Predefined Variables</a></li>
<li><a href="#Preferences Variables"> Preferences Variables</a></li>
<li><a href="#Setting Preferences"> Setting Preferences</a></li>
</ul>
</div>
-## <a name="TWiki Variables"></a> TWiki Variables
+# <a name="TWiki Variables"></a> TWiki Variables
+
+_Text strings expanded on the fly include predefined, preference-driven and custom-defined data_
+
+## <a name="Overview"></a> Overview
TWikiVariables are text strings enclosed in percentage signs: <code>**%VARIABLE%**</code> that represent stored data. When a topic is rendered for viewing, defined variables are replaced by their actual values. TWiki has two types of variable, predefined and Preference-based, where usually you determine the content. Through Preference variables, you can also define custom variables, creating new variable name and value. TWiki variables are as simple to use as they are powerful, and vice versa!
-### <a name="Predefined Variables"></a> Predefined Variables
+## <a name="Predefined Variables"></a> Predefined Variables
With a couple of notable exceptions, predefined variables return set values that are defined one-time on installation and left alone. Most are directory names and file paths, customized for your server, and only have to be updated once in the main configuration file if your server set-up changes.
<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:29:26</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:29:33</b></td>
</tr>
<tr>
<td><code>%SERVERTIME%</code></td>
>
> [2] **_Note_**: A web can be excluded from a `web="all"` search if you define a `NOSEARCHALL=on` variable in its [[WebPreferences]].
-### <a name="Preferences Variables"></a> Preferences Variables
+## <a name="Preferences Variables"></a> Preferences Variables
Additional variables are defined in the preferences ( site-level ( **_SL_** ) in [[TWikiPreferences]], web-level ( **_WL_** ) in [[WebPreferences]] of each web, and user level ( **_UL_** ) preferences in individual user topics):
<td> List of preferences that are not allowed to be overridden by next level preferences</td>
</tr></font></font></table>
-### <a name="Setting Preferences"></a> Setting Preferences
+## <a name="Setting Preferences"></a> Setting Preferences
- 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>
-### <a name="Creating Custom Variables"></a> Creating Custom Variables
+## <a name="Creating Custom Variables"></a> Creating Custom Variables
- 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, image paths.