Replacement Variables

ConferenceRoom's included web server offers an advanced language for embedding commands and interactivity in the web pages it serves. Some of these features are used in our theme pages and administration pages. A thorough understanding of these features will allow you to build more interesting and interactive web pages.

Note that these features will only work on .adm, .htm, .html, or .prm files served off of ConferenceRoom's included web server. This documentation assumes you have version 1.6.7 or later -- not all features will be available in earlier versions.

Text in this font is normal text meant to be read and understood. Text in this font is meant to be used literally as a command, value, or as source code. Text in this font is meant to be replaced with what it names, for example name should be replaced with something's name or channel should be replaced with a channel.

All commands begin and end with the % character. If you want to use a normal %</b> character, you should double it -- <b>%% to ensure that it is not seen as a command. If you want to make web pages that work on both our web server and other web servers, ensure that there are never two % signs on the same line of HTML source.

Do not do the following:
We estimate the probability to be between 80% and 85%.
The text between the two % signs will be seen as a replacement variable. If you are only using our web server, you may use:
We estimate the probability to be between 80% and 85%.
This will cause the page to not work correctly on other web servers. If you want a portable page, you can do:
We estimate the probability to be between 80%
and 85%.

ConferenceRoom's web server will not look across lines.

The most basic thing you can do is access replacement variables. Replacement variables can be fetched by name. They can be set by code embedded in the web server, tags in the URL, or by fields posted from a form. To set a tag from a URL or form, you must precede its name with an @ character.

For example, the line:
Hello, %name%.
Will say:
Hello, Jack.
if accessed with:
?@name=Jack
on the end of the URL or through a form submission with:
<input type="text" name="@name">
and the person enters:
Jack.

Parts of a web page may be made conditional upon a replacement variable being set. The syntax for this is:
%!name%
HTML that will be ignored if the variable is not set
%!!%

So, you can make a web page that says hello to someone only if their name has been set:

%!name%
Hello, %name%.
%!!%