For more information... RTFM!
NAVIGATION
PAGES THAT LINK HERE
ACCOUNT LOGIN

You are not logged in

Powered by Interchange version 5.7.0

VariableDatabase

Specify a database file or table containing variable names and values.

Synopsis

VariableDatabase  name

Scope

This directive is only available for use in the local (catalog.cfg) configuration file.  It will not affect any other website in any way.  This directive will not work in the global (interchange.cfg) configuration file. 

Description

This directive can be used to specify the name of a database file or table containing Interchange variable names and values, saving you from having to clutter up your configuration file(s) with long lists of Variable definitions.

For example, a database file can be defined as:

Database          var  var.txt  TAB
VariableDatabase  var

If the file contained the following lines:

code Variable
HELLO Hi!

then "__HELLO__", in a page file, would appear as "Hi!" in the parsed and rendered output.

Note that the Variable field name is case-sensitive.

Note also that only the first two tab-separated columns will be read into Variables;  Any further columns will be ignored.

The Variable values are read when Interchange is (re)started or the website is reconfigured.  Any single-level hash-orientated Interchange directive, such as SpecialPage, ScratchDefault or ValuesDefault, can be set in the same way.

If the named VariableDatabase file or table does not exist when Interchange starts, a file of the default type, with an ASCII source file appended with ".txt will be is assumed.  In other words:

VariableDatabase variable

would be equivalent to:

Database          variable  variable.txt  TAB
VariableDatabase  variable

Category:  Local config directives
Last modified by: Kevin Walsh
Modification date: Wednesday 23 August 2006 at 9:57 AM (EDT)
Home  |  Legal nonsense  |  Privacy policy  |  Contact us