At startup, all CMS server applications first read their system configuration. Then they check the availability of the database configured and create new database tables if required. With SQLite, the database itself is also created if it does not exist.
During the initialization procedure, Tcl scripts are read from the following directories.
share/script/common/clientCmds share/script/app/clientCmds share/script/common/serverCmds share/script/app/serverCmds instance/default/script/common/clientCmds instance/default/script/app/clientCmds instance/default/script/common/serverCmds instance/default/script/app/serverCmds
In the paths listed above,
app stands for the
application-specific script directory
ses. Please note that the Template Engine reads the
scripts of the Content Management Server at startup. Scripts in the
directories are read by all applications at startup.
Scripts contained in the directories listed in the first group are common to all instances and are read by the corresponding CMS applications, independently of the instance.
You can place your instance-specific scripts in the directories listed in the second group. These scripts are read after the scripts of the first group so that procedures stemming from the first group can be redefined by instance-specific procedures if required.
When a dump is generated, only the instance-specific scripts are saved. Analogously, when a dump is restored, the instance-specific script directories are reset to the contents of the dump (in fact, the instance-specific script directories are deleted prior to restoring the dump). See also Dumping and Restoring Data.
The script files contained in the directories listed above are sorted alphabetically (ASCII) and then read in ascending order.
The server commands from the
serverCmds directories are
available only in commandline mode while the client commands (from the
clientCmds directory) can be used in single mode (commandline
-single) and in the Tcl client (under a different
name, if applicable, see below) as well as in Tcl procedures.
Finally the Content Manager executes the script
usermanAPI.tcl at startup. The functions defined in
this file represent the interface the applications use for communicating
with the integrated or an external user manager.