Troubleshooting the image cache
Templates are not being displayed by the interview
If the pages of the interview are returned with a white background and do not use the specified template, the Web Service cannot load the template file; it writes an error message to the IVW log file on the Web server. By default, the IVW logs are stored in:
[INSTALL_FOLDER]\IBM\SPSS\DataCollection\<version>\Interviewer Server Administration\Logs
The first step when debugging a template issue is to find the log entry for the error. The main reasons why a template cannot be loaded are as follows:
The template is not well-formed XML
Templates must be written in well-formed XML. This means that every tag must have an opening and a closing tag so, for example, you must always write <br/> rather than just <br> to create a line break. If the XML in your template is not well formed, a parsing error appears n the log files. For example:
Error parsing template
'http://SVR1/SPSSMR/ImageCache/ImageCache.aspx?Project=englishmuseum&File=Card_Blue.htm', line 33:
End tag 'TR' does not match the start tag 'TD'.
The Web Service was unable to load the template
If the Web Service cannot load the template, it writes an error message detailing the Project and Global locations that it used to find the template. For example:
Unable to load template 'Card_Blue.htm'. Using default template.
Project location='http://SVR1/SPSSMR/ImageCache/ImageCache.aspx?Project=englishmuseum&File='. Template location='[INSTALL_FOLDER]\IBM\SPSS\DataCollection\<version>\Interviewer Server\Server\mrIWeb\Templates\'.
The first step is to confirm the template cannot be loaded by testing the Image Cache URL in a browser on the web server. For example, type:
http://SVR1/SPSSMR/ImageCache/ImageCache.aspx?Project=englishmuseum&File='card_blue.html
into the Address box in the browser. The error in the browser should give some indication as to why the file cannot be retrieved. One common problem is that the Web server does not have access to the Master project folder. In this case, the Image Cache needs to be configured to load images from a remote Image Cache. See
How to configure the image cache for more information.
Another common scenario is that the Web server cannot resolve the server name in the file’s URL. Try replacing the server name with “localhost” or with the computer’s IP address.
When you have a URL that works, change the
LocalImageCache setting in the Web Service’s configuration file (see
How to configure the image cache). Reset the Web server to pick up the new configuration setting: see
Resetting IIS and the services.
Images are not displayed in the respondent’s browser
If templates are being displayed but the images specified in your interview script are not, the Image Cache URL is probably configured incorrectly. To test the Image Cache URL, extract the URL from the src attribute in the interview HTML source and test the URL from an external client computer. For example, type:
http://svr1/SPSSMR/ImageCache/ImageCache.aspx?Project=englishmuseum&File="Image1.gif"
into the Address box of your browser. Replace & in the src attribute with just &, as shown here. The error in the browser should give some indication as to why the file could not be returned.
The URL should not be tested on the Web server.
See also