data/TWiki/TWikiVariablesQuickStart.txt,v
author Colas Nahaboo <colas@nahaboo.net>
Sat, 26 Jan 2008 15:50:53 +0100
changeset 0 414e01d06fd5
permissions -rw-r--r--
RELEASE 4.2.0 freetown
     1 head	1.3;
     2 access;
     3 symbols;
     4 locks; strict;
     5 comment	@# @;
     6 
     7 
     8 1.3
     9 date	2008.01.22.03.21.35;	author TWikiContributor;	state Exp;
    10 branches;
    11 next	1.2;
    12 
    13 1.2
    14 date	2007.01.16.04.12.02;	author TWikiContributor;	state Exp;
    15 branches;
    16 next	1.1;
    17 
    18 1.1
    19 date	2006.06.25.16.26.27;	author TWikiContributor;	state Exp;
    20 branches;
    21 next	;
    22 
    23 
    24 desc
    25 @buildrelease
    26 @
    27 
    28 
    29 1.3
    30 log
    31 @buildrelease
    32 @
    33 text
    34 @%META:TOPICINFO{author="TWikiContributor" date="1167863098" format="1.1" version="3"}%
    35 ---++ TWiki Variables Quickstart
    36 
    37 %STARTINCLUDE%
    38 
    39 TWiki Variables are names enclosed in percent signs that are that are expanded to some other text when the topic
    40 is displayed. For example, =%<nop>TOPIC%= is expanded to %TOPIC%.
    41 Some variables can take arguments in curly braces - for example, =%<nop>INCLUDE{"OtherTopic" ARG="arg"}%=.
    42 
    43 Many TWiki variables are built-in, and others are predefined for your convenience. You can also define your own
    44 TWiki Variables at the entire site, individual web, or individual topic level. For more information,
    45 go to *[[TWikiVariables]]*
    46 
    47 TWiki Variables are fully expanded _before_ any of the TWiki text formatting rules are applied.
    48 
    49 *Documentation Graphics:* There are many graphics available to use in your topics. Use =%<nop>ICON{"help"}%=, =%<nop>ICON{"tip"}%=, and =%<nop>ICON{"warning"}%= to get: %H%, %T%, and %X%, respectively. TWikiDocGraphics lists them all.
    50 
    51 %ICON{"tip"}% To "escape" a variable, prefix it with an exclamation mark. Write: =!%<nop>SOMEVARIABLE%= to get: !%SOMEVARIABLE%.
    52 %STOPINCLUDE%
    53 @
    54 
    55 
    56 1.2
    57 log
    58 @buildrelease
    59 @
    60 text
    61 @d1 1
    62 a1 1
    63 %META:TOPICINFO{author="TWikiContributor" date="1167863098" format="1.1" version="2"}%
    64 d6 7
    65 a12 1
    66 TWiki Variables are names that are enclosed in percent signs =%= that are expanded on the fly. Some variables take arguments, such as =%<nop>INCLUDE%=. For those variables, the arguments are included in curly braces ({ and }).
    67 d14 1
    68 a14 13
    69 | *Variable* | *In brief* | *Full documentation* |
    70 | =%<nop>TOC%= | Automatically generates a table of contents based on headings in a topic - see the top of this page for an example. |VarTOC |
    71 | =%<nop>WEB%= | The current web, is <b><nop>%WEB%</b>. | VarWEB |
    72 | =%<nop>TOPIC%= | The current topic name, is <b>%BASETOPIC%</b>. <!-- using BASETOPIC instead of TOPIC for the example because this document is normally included in TextFormattingRules --> | VarTOPIC |
    73 | =%<nop>ATTACHURL%= | The attachment URL of the current topic. Example usage: If you attach a file to a topic you can refer to it as =<b>%<nop>ATTACHURL%/image.gif</b>= to show the URL of the file or the image in your text. | VarATTACHURL |
    74 | =%<nop>INCLUDE{"SomeTopic"}%= | Server side include, includes another topic. The current web is the default web. Example: =<b>%<nop>INCLUDE{"%TWIKIWEB%.SiteMap"}%</b>= | VarINCLUDE |
    75 | =%<nop>SEARCH{"sushi"}%= | Inline search showing the search result embedded in a topic. FormattedSearch gives you control over formatting, useful for creating web-based applications. | VarSEARCH |
    76 
    77 TWikiPreferences defines some site-wide variables. Among them are:
    78    * *Line break:* Write =%<nop>BR%= to start a new line.
    79    * *Colored text:* Write: =%<nop>RED% Red %<nop>ENDCOLOR% and %<nop>BLUE% blue %<nop>ENDCOLOR% colors= to get: %RED% Red %ENDCOLOR% and %BLUE% blue %ENDCOLOR% colors.
    80 
    81 There are many more variables. To see them all, go to *[[TWikiVariables]]*.
    82 a17 1
    83 
    84 @
    85 
    86 
    87 1.1
    88 log
    89 @buildrelease
    90 @
    91 text
    92 @d1 1
    93 a1 1
    94 %META:TOPICINFO{author="TWikiContributor" date="1142354264" format="1.1" version="1"}%
    95 d22 1
    96 a22 1
    97 *Documentation Graphics:* There are many graphics available to use in your topics. Use =%<nop>ICON{"help"}%=, =%<nop>ICON{"tip"|%=, and =%<nop>icon{"warning"}%= to get: %H%, %T%, and %X%. To see all of the graphics available, see TWikiDocGraphics.
    98 @