ImageDir — specify base location for all image files
ImageDir is one of quite basic settings in every catalog.cfg.
The directive specifies a base location, accessible over the web,
where Interchange should look for IMG and INPUT HTML
src= file specifications.
To be precise, actually, this setting applies to image locations mentioned
in
<img src="">, <input src="">, <body background="">, <table background=""> and table subelements (<th>, <tr> and <td>).
As you might know, Interchange keeps its pages in a special directory
pages/ (which is a subdirectory of
your catalog's CATROOT). That directory can be readable only by the
Interchange user, and contents in it cannot be accessed by the web server without
Interchange mediating the connection. This directory is generally supposed to
only contain directories and Interchange-enabled HTML pages,
nothing else.
It is therefore obvious that an alternative way has to be provided
to serve images. When you define ImageDir, Interchange will appropriately
and transparently prefix all <img src=...> HTML tags with
your value.
For example, if the link program and images are kept on the same
server, and images are found in your web server's document root,
in the images/ subdirectory, then
you would set ImageDir to /images/.
With this setting in effect, a link such as <img src="order.png">
would automatically be translated to <img src="/images/order.png">.