5. Template design

The syntactical conventions for transformation of text content units are very easy. Each field in an Inter-Publish form has a fieldname. Substitution is generally in the format:

<<fieldname>>

For example, to substitute the Title field simply requires a tag:

<<Title>>

Similarly, the web page contents are generally inserted using:

<<Document>>.

Additional tag formats are:

<<fieldname>> show the contents of the field
<<Upper_elementname>> show field contents in upper case
<<Lower_elementname>> show the field data in lower case
<<bbcode_elementname>> Apply bbcode styling to this element
<<Strip_elementname>> show data stripped of special characters and with spaces removed
<<Split_elementname>> show the data with all special characters removed and spaces replaced with "_"
<<HTMLEncode_elementname>> apply html encoding to the contents of the field
<<Mailto_elementname>> insert the text mailto: in front of an email field if none is already present
<<URL_elementname>> insert the text http:// in front of a URL field if none is already present
<<Flash_elementname>> strips html encoding that is not compatible with flash-format html content
<<StripBR_elementname>> Removes
tags and line feeds to make a single line of text
<<XMLEncode_elementname>> Show the data XML encoded
<<Count_elementname>> A tabular total of survey occurrences for a particular document
<<Image>> Location to insert the binary contents of the Image data

These tags define the point within static content that database or other information is to be inserted. There are some tags designed for specific use in indexes and in document publishing. Others insert static information such as current date or time.