WPP 2.13.1.35 - The Web Preprocessor
Author: Marco Lamberto |
||
Index | < Previous Next > |
Directives |
@INCLUDE name@Include a template. The 'namè value is expanded by searching into the @DEFAULT_TMPLPATH@ directories a file with the wanted name and the extension specified with @DEFAULT_TMPL_EXTENSION@.
@DEFAULT_TMPLPATH=pub:my_templates:templates@
MENU hhh iii jjj kkk lll mmm
DRINKS aaa bbb ccc ddd eee fff ggg
<!-- includes pub/menu.tmpl --> @INCLUDE menu@ <!-- includes pub/drinks/menu.tmpl --> @INCLUDE drinks/menu@
MENU hhh iii jjj kkk lll mmm DRINKS aaa bbb ccc ddd eee fff ggg
@IF test@ ... [@ELSE@ ...] @ENDIF@
Test | Description | Example |
---|---|---|
var | It's true if the variable "var" is defined (it's value is something different from an empty string). |
@IF MYVAR@ |
!var | It's true if the variable "var" is not defined (it's value is an empty string). |
@IF !MYVAR@ |
var == "val" | It's true only if the value associated to the variable "var" is equal to the value specified by "val". |
@IF MYVAR == "some value"@ |
var != "val" | It's true only if the value associated to the variable "var" is different from the value specified by "val". |
@IF MYVAR != "another value"@ |
@IF SHOW_IMAGE@ graphic map @ELSE@ text description @ENDIF@ @IF !SHOW_IMAGE@ text map @ELSE@ @IF IMAGE_DESC=="Test"@ test @ENDIF@ image @ENDIF@
$Date$This is the standard RCS $Date$ tag. The header file will be included only when this tag is reached.
@HEAD tmpl@Use a different header from @DEFAULT_HEAD@. If 'tmpl' is omitted no header is included. This directive MUST precede the RCS $Date$ tag. The 'tmpl' is the filename without the leading templates directory (a @DEFAULT_TMPLPATH@ entry) and the extension (@DEFAULT_TMPL_EXTENSION@).
@TAIL tmpl@Same as @HEAD@ but works only on the footer template (@DEFAULT_TAIL@) and doesn't need to precede the $Date$ tag.
@INLINE@ ... @ENDINLINE@Allows perl code inlined within raw sources.
^ Top | < Previous Next > | |
Marco (LM) Lamberto lm@sunnyspot.org
Revised: 2003/03/10 07:38:04 http://wpp.sf.net/manual_5.html |