Templates must contain the magic string
mapserver template in the first line of the template.
This line is not written to the client.
The magic string is not case sensitive.
MapServer will only accept certain file extensions for templates; valid file extensions are:
All CGI parameters can be referenced in template substitutions, MapServer specific parameters as well as user defined ones. In principle parameters are handed through by the MapServer 1:1. This feature is essential for implementing MapServer applications.
The reference below only lists special template substitution strings which are needed to obtain information modified by the MapServer, e.g. a new scale, query results, etc.
Template substitution strings are case sensitive.
Attribute item substitutions must be the same case as the item names in the dbase file.
ArcView and ArcInfo generally produce dbase files with item names that are all uppercase. Appropriate URL encoding (i.e. ‘ ‘ to ‘+’) is applied when templates are URLs.
Some substitutions are also available in escaped form (i.e. URL encoded).
In HTML files, the attribute values can be inside quotes(“”). Writing attribute values inside quotes allows you to set special characters in value that you couldn’t use normally (ie: ],=,” and space). To write a single quote in a attribute value, just use two quotes (“”).