Loading images from a custom location

By default, the Management Center loads catalog images from the store directory within the Stores web application. If your store retrieves images from a different location, you must configure this custom location so that the Management Center can locate your images.

About this task

If you want to load your images from a location other than the default location, you must configure the image loading servlet to locate images from a custom location.

Procedure

  1. Open WebSphere Commerce Developer and switch to the Enterprise Explorer view.
  2. Expand LOBTools > WebContent > WEB-INF and locate the web.xml file.
  3. Within the web.xml file, add the imageURLPrefix initialization parameter to the <servlet-name>ImageServlet</servlet-name> section.
    For example:
    <!-- Image Serving Servlet -->
    	<servlet>
    		<servlet-name>ImageServlet</servlet-name>
    		<servlet-class>com.ibm.commerce.foundation.client.lobtools.servlet.ImageServlet</servlet-class>
    		<init-param>
    			<param-name>imageURLPrefix</param-name>
    			<param-value>http://myImageServletHost/webapp/wcs/stores/Madisons/</param-value>
    		</init-param>
    		<load-on-startup>2</load-on-startup>
    	</servlet>
  4. Save your changes.

What to do next

After you complete your work:
  1. Test your changes by viewing them in the Management Center, using this URL: https://hostname:8000/lobtools.
  2. If you started the WebSphere Commerce Server to test your changes, stop and then restart the WebSphere Commerce Server.
  3. Deploy your changes to your production environment.