|
META TOPICPARENT |
name="WebHome" |
|
|
Overview |
|
< < | TWikiVariables are text strings - %VARIABLE% - that expand into content whenever a page is opened. Variables are replaced by their actual values: stored data, or system info (like the date, or the current user). There are predefined variables, and Preference variables that you set. You can also define custom variables, with new names and values. |
> > | TWikiVariables are text strings - %VARIABLE% - that expand into content whenever a page is opened. When a topic is rendered for viewing, VARIABLES are replaced by data, either user-entered, or info automatically generated by TWiki (like the date, or the current username). There are predefined variables, and Preference variables that you configure. You can also define custom variables, with new names and values. |
|
Predefined Variables |
|
< < | Most predefined variables return values that were either defined when TWiki was installed, or taken from server info (like current username, or date and time). Many of the variables let you control how the formatted results appear. |
> > | Most predefined variables return values that were either set in the lib/twiki.cfg file, when TWiki was installed, or taken from server info (like current username, or date and time). Many of the variables let you format the appearance of the display results. |
| |
|
< < | The Caboteria expands the following variables (enclosed in % percent signs): |
> > |
-
Take the time to thoroughly read through ALL preference variables. If you actively configure your site, review variables periodically. They cover a wide range of functions, and it can be easy to miss the one perfect variable for something you have in mind. For example, see %INCLUDINGTOPIC% , %INCLUDE% , and the mighty %SEARCH% .
This version of TWiki - TWiki-5.1.4, Sat, 16 Feb 2013, build 25114 - expands the following variables (enclosed in % percent signs): |
|
|
| Returns the value of a URL parameter. Ex: %URLPARAM{"skin"}% returns print for a .../view/TWiki/TWikiVariables?skin=print URL. Is |
%WIKITOOLNAME% | |
|
< < | Name of wiki tool, is The Caboteria | |
> > | The name of your TWiki site - The Caboteria | |
| |
|
< < | Wiki tool version is TWiki-5.1.4, Sat, 16 Feb 2013, build 25114 | |
> > | Your current TWiki version - TWiki-5.1.4, Sat, 16 Feb 2013, build 25114 | |
| |
|
< < | Your login username is guest | |
> > | Your login username - guest | |
|
%WIKINAME% |
Your Wiki username. Same as %USERNAME% if not defined in the TWikiUsers topic. Is TWikiGuest |
%WIKIUSERNAME% |
|
|
< < | Your %WIKINAME% including the Main web name. Usefull for signatures. Is Main.TWikiGuest | |
> > | Your %WIKINAME% including the Main web name - always use full signatures - Main.TWikiGuest | |
| |
|
< < | |
> > | |
| |
|
< < | The web containing all documentation and configuration of The Caboteria is TWiki | |
> > | The web containing all documentation and site-wide preference settings for The Caboteria - TWiki | |
|
%WEB% |
The current web is TWiki |
|
| The web name where the includes started, e.g. the web of the first topic of nested includes. Same as %WEB% in case there is no include. |
%INCLUDINGWEB% | |
|
< < | The web name of the topic that includes the current topic. Same as %WEB% in case there is no include. | |
> > | The web name of the topic that includes the current topic - same as %WEB% if there is no INCLUDE. | |
| |
|
< < | The home topic in each web. Is WebHome | |
> > | The home topic in each web - WebHome | |
| |
|
< < | |
> > | |
| |
|
< < | The index topic of all registered users. Is TWikiUsers | |
> > | The index topic of all registered users - TWikiUsers | |
| |
|
< < | The web preferences topic. Is TWikiPreferences | |
> > | The site-wide preferences topic - TWikiPreferences | |
| |
|
< < | The web preferences topic. Is WebPreferences | |
> > | The local web preferences topic in each web - WebPreferences | |
| |
|
< < | The web statistics topic. Is WebStatistics | |
> > | The web statistics topic WebStatistics | |
| |
|
< < | The current topic name, is TWikiVariables | |
> > | The current topic name - TWikiVariables | |
| |
|
< < | The name of the topic where the includes started, e.g. the first topic of nested includes. Same as %TOPIC% in case there is no include. | |
> > | The name of the topic where a single or nested INCLUDE started - same as %TOPIC% if there is no INCLUDE. | |
|
%INCLUDINGTOPIC% |
The name of the topic that includes the current topic. Same as %TOPIC% in case there is no include. |
|
| %TOPICLIST{" <option>$name</option>"}% creates an option list (for drop down menus).
%WEBLIST{"format"}% | |
|
< < | Web index, e.g. list of all webs. Hidden webs are excluded, e.g. webs with a NOSEARCHALL=on preference variable. The "format" defines the format of one web item. The $name variable gets expanded to the name of the web, $qname gets expanded to double quoted name, $marker to marker where web matches selection . | |
> > | Web index, ex: list of all webs. Hidden webs are excluded, e.g. webs with a NOSEARCHALL=on preference variable. The "format" defines the format of one web item. The $name variable gets expanded to the name of the web, $qname gets expanded to double quoted name, $marker to marker where web matches selection . | |
| Parameters are format, separator and web:
|
|
[1] Note: The search form uses identical names for input fields. |
|
< < | [2] Note: A web can be excluded from a web="all" search if you define a NOSEARCHALL=on variable in its WebPreferences. |
> > | [2] Note: A web can be excluded from a web="all" search if you define a NOSEARCHALL=on variable in its WebPreferences. |
|
Preferences Variables |
|
Setting Preferences |
|
< < |
- The syntax for Preferences variables is the same anywhere in TWiki. In Edit mode, from the start of a new line:
[6 spaces] * [space] Set [space] VARIABLENAME [space] = [value] Example:
|
> > |
- The syntax for Preferences variables is the same anywhere in TWiki (on its own TWiki bullet line, including nested bullets):
[3 spaces] * [space] Set [space] VARIABLENAME [space] = [value] Examples:
-
Set VARIABLENAME = =value=
-
Set VARIABLENAME = =value=
|
|
Creating Custom Variables |
|
-- PeterThoeny - 13 Sep 2001
|
|
< < | -- MikeMannix - 30 Nov 2001 |
> > | -- MikeMannix - 05 Jan 2002 |