The DIML solution will have provision to pass strings and variables through the DIML interface. The following example shows how the ESSI Processor subtitutes variables recursively, until all ESSI statements are processed. In some cases, specially when some fragments should be encapsulated, it is convenient to pass variable definitions from the designer side to the script author side. Template contents is not part of the document body, unless ESSI statements will ask for template substitution. Robustness principles will ask ensuring that templates will be parsed even in a document body.
Correct process isolates the template and stores it into a internal data base.
If templates are pointing to other files, the processor will extract template definition opening an extra template file. To verify this process, you should have a look at the source code of the present document. The following lines should include two META tags into the head of the present document, along with a small javascript function. Iterations ESSI processor brings much more than simple data substitution. What follows shows how to use iterative calls to construct large HTML tables based on a request in a database.