Interviewer - Server > Architecture > Web Service tier > Image/Template cache > How the image cache is used > Where the web tier looks for templates
 
Where the web tier looks for templates
The Web Service supports the localization of HTML templates, and is able to search for templates in a number of folders and subfolders based on the respondent’s browser language, or the language specified in the interview script. For example, if the language is passed as "en–us", the HTML Player looks for the template in these locations:
Project Location/en–us
Project Location/en
Project Location/
Global Location/en–us
Global Location/en
Global Location/
Once the HTML Player finds the specified template, the Player uses it to render the interview page. If the specified template is not found, the Player writes an error message to the IVW log file on the Web server and uses a default template instead.
When the Image Cache is enabled (UseImageCache="true"), Project Location is the Local Image Cache URL.
Global Location can be defined by adding the TemplateLocation key in the mrIWeb Web.config file. The default setting is:
<add key="TemplateLocation" value="http://ServerName/SPSSMR/ImageCache/ImageCache.aspx?File=" />
When the UseGlobalTemplate key is set to True, templates are first searched from the global location before checking the project location.
<add key="UseGlobalTemplate" value="true" />
The default sample management authentication templates are installed to this directory. To reference files in another location, update the TemplateLocation key value in the mrIWeb Web.config file to that directory.
To reduce the number of calls between the Web Tier and the Interview Tier, the Image Cache performs the language-culture folder search automatically. This reduces the number of "HTTP 404; Not Found" errors returned by the Interview Tier. An excessive number of 404 errors can cause traffic to be blocked by firewalls.
Note Failing to activate templates reduces server performance as the Web Tier searches for the missing template. It also causes a high number of HTTP 404 errors between the Web and Interview Tiers. If the Image Cache is used, activate all templates with the project, and do not use the Global Location.
See also
How the image cache is used