Soporific for novice, this page gives to regular users the precise
behavior of each WebSitePP tag.
<PAGE PageName>
Declares a new web page called PageName.
This tag must be closed with </PAGE>.
PageName may contain alphanumeric characters and "_" and "/".
PageName may contain a path before the page name.
The extension (default is ".html") is automatically added when
pages are generated, that is why it is forbidden to add it in the
page name.
A PAGE tag cannot be contained in another tag.
Macro-instruction (or variable) modification while in a PAGE tag
are not seen in other pages.
<DEFINELANG LangName />
Declares a language called LangName.
This tag is stand-alone (no close tag </DEFINELANG>).
Calling it without the ending "/" is supported.
LangName may contain alphanumeric characters and ".", "-", "_", "#" and "/".
Except for the first declared, other declared language change the
filename generated for a page by adding their name.
A DEFINELANG tag cannot be contained in another tag.
<L LangName>
The content of this tag is seen only in pages for the language LangName.
This tag must be closed with </L>.
LangName may contain alphanumeric characters and "." and "/".
LangName must have been declared before as a supported language.
A L tag must be inside a PAGE tag, directly or not.
<DEFINE MacroName> ou
<DEFINE MacroName Value />
Defines the content of the macro-instruction MacroName.
MacroName may contain uppercase alphanumeric characters and "_".
Without second argument, this tag must be closed with </DEFINE>.
With a second argument, this tag is stand-alone (no close with
</DEFINE>) and the content of the macro-instruction is Value.
Calling it without the ending "/" is supported. This calls behave
like a string variable assignment. Value
may contain alphanumeric characters and ".", "-", "_", "#" and "/".
It may be located in any place. However, definition or modification
of macros inside a page will not be seen externally. This
behavior is compatible with the per page "ifndef then define" to
avoid multiple definitions.
Macro evaluation is done at page generation time and for a given language.
<USEPARAM ParamNumber />
This tag is located only inside a DEFINE tag.
This tag is stand-alone (no close with </USEPARAM>).
Calling it without the ending "/" is supported.
It is replaced with the parameter number ParamNumber
given when calling the macro.
ParamNumber is a number. The first parameter is parameter
number zero.
<PARAM>
This tag defines the value of a parameter when a macro is called.
It must be closed with </PARAM>.
It must be located just after and at the same hierarchical level
than the macro call ( <TOTO> <L fr>
<PARAM> param </PARAM> </L> is not
correct).
Its quantity must be consistent with the values of the USEPARAM tag
used when defining the macro.
It may contain some macro calls and some USEPARAM tag if the call
is in a macro definition...
<RELPATH FileName />
For FileName given from the site root, this tag is replaced
with the filename from the directory of the current page.
This tag is stand-alone, (no close with </RELPATH>).
Calling it without the ending "/" is supported.
If FileName has the special value USEPARAMn
with n a number, then the filename will be the value of the
parameter n (this is allowed only inside a DEFINE
tag). This makes up for the impossibility to put a WebSitePP tag
inside the brackets of another WebSitePP tag ( <TOTO <TITI> > is
not correct).
<PAGEFILENAME PageName LangName />
This tag is replaced with the filename of the given page name with
the given language, from the directory of the current page.
This tag is stand-alone, (no close with </PAGEFILENAME>).
Calling it without the ending "/" is supported.
The result takes into account the prefix and the suffix of the files.
If PageName has the special value SELF, then the filename is
the one of the current page.
If PageName has the special value USEPARAMn
with n a number, then the filename is the value of the
parameter n (this is allowed only inside a DEFINE
tag). This makes up for the impossibility to put a WebSitePP tag
inside the brackets of another WebSitePP tag.
If LangName has the special value SELF, then the language
name is the current one.
If LangName has the special value USEPARAMn
with n a number, then the language name will be the value of
the parameter n (this is allowed only inside a DEFINE
tag). This makes up for the impossibility to put a WebSitePP tag
inside the brackets of another WebSitePP tag.
The page filename for the first declared language is made with the
prefix (default is "Site/"), the name of the page and the suffix
(default is ".html").
The page filename for other languages is made with the
prefix, the name of the page, "_" followed
by the language name, and the suffix.
<IF TestType MacroName> or
<IF TestType MacroName Value>
This tag manages the conditional inclusion of text.
It must be closed with </IF>.
TestType must have the value EQUAL or NEQUAL.
The value of the macro MacroName gives the first term of the
test.
If Value is present (string without space), it represents the second
term of the test. If not, the test is an existence test of the
macro (equivalent to ifdef and ifndef).
If the test is fulfilled (equality or inequality), the
content of the tag is kept, else it is ignored.
If a tag <ELSE/> (<ELSE> accepted) is present inside the
IF tag, it splits the text into two parts. If the test is
fulfilled, then only the first part is kept, else the second part.
If MacroName has the special value SELF_PAGENAME,
then the value of the first term is the name of the current page.
If MacroName has the special value SELF_LANG,
the the value of the first term is the name of the current language.
If MacroName has the special value USEPARAMn
with n a number, then the value of the first term is the value
of the parameter n (this is allowed only inside a DEFINE
tag). This works for existence test too.
If Value has the special value USEPARAMn
with n a number, then the value of the second term is the
value of the parameter n (this is allowed only inside a DEFINE tag)
<INCLUDE FileName />
This tag includes the description file FileName
into the calling description file.
The start directory is the one from which WebSitePP has been launched.
This tag is stand-alone, (no close with </INCLUDE>).
Calling it without the ending "/" is supported.
An included file may include.
This tag cannot be contained in another tag.
Hint: Use the function to separate generic macro libraries (HTML,
Javascript, ...), site specific macro libraries, and the site
pages with their content. The ideal input file is made only out
of INCLUDE tags.
/ * Comments * /
Comments are similar to the ones of the C language.
All text between / * and * / will not be processed,
whatever the line quantity.
A comment may start or stop everywhere, even in a WebSitePP tag brackets.
|