Aurigma Image Uploader 4.8 Dual
Updating Image Uploader on the Client Side
See Also

From time to time new versions of Image Uploader with new features and bug fixes is released. If you just replace ImageUploader4.cab and ImageUploader2.jar you will find out that old version is still used.

It happens because the browser caches ActiveX controls and Java applets. It allows to avoid re-downloading them every time the user reloads the page. Therefore it reduces traffic and increases response time. However it requires some additional efforts to update Image Uploader. This topic discusses how to do it.

There are two ways to update the control:

- Automatic Update
- Manual Update

Also, for ActiveX version, you can use a standalone installer.

# Automatic Update

The most convenient and wide-spread way to update Image Uploader on client computers is to specify version information in the HTML code that embeds it to the page. It works in the following way:

1. The browser stores the version of Image Uploader when it is installed at the first time.
2. When the page is reloaded, the browser compares the version of installed Image Uploader with the version specified in this page.
3. If the version specified in the page is higher that the version of the installed Image Uploader, the browser automatically downloads the new version. Otherwise, it uses the version from the browser cache.

Helper iuembed.js script exposes all necesary members to do it. Let's see how to update ActiveX and Java version using iuembed.js .

##### ActiveX

The version of ActiveX control is specified with the activeXControlVersion property. To get a version number of ActiveX control, you can:

1. Unpack ImageUploader4.cab . You can do it in the same manner as you unpack common ZIP or RAR archives.
2. Click the OCX file from ImageUploader4.cab with a right mouse button.
3. Select Properties menu item.
4. Click the Version tab.

Also, the version number is specified on the Image Uploader SDK download page.

Note
Numbers inside the version string should be separated with comma. For example, 4,0,43,0.

Here is an example of the activeXControlVersion usage:

HTML (ActiveX Only Compatible) | Copy Code
--- | ---
    <script language="javascript">
    var iu = new ImageUploaderWriter("ImageUploader1", 610, 500);

    iu.activeXControlEnabled = true;
    iu.activeXControlCodeBase = "ImageUploader4.cab";
    iu.activeXControlVersion = "4,0,43,0";

    iu.writeHtml();
    </script>

To update ActiveX version of Image Uploader

1. Copy new ImageUploader4.cab to the server instead of the old one.
2. Insert new version number to the activeXControlVersion property of the ImageUploaderWriter.

Important
It is highly recommended to close all browsers which host Image Uploader. It is necessary to avoid a message prompting to restart computer. See the FAQ: Installation Problems topic for more details.

##### Java

The iuembed.js provides Java version with the analogous property - javaAppletVersion. It specifies the version of the ImageUploader2.jar used to compare the version from the browser cache with the version on the server.

Additionally, there is a javaAppletCached property which specifies whether Java applet caching feature is enabled. If it is false, the applet is always re-downloaded from the server regardless to the version number.

Note
The applet caching may be disabled by the user. So if you set the javaAppletCached to true, and the caching still does not work, make sure the Enable Caching checkbox is not cleared in the Java control panel (see screenshots in the Manual Update section).

This code snippet demonstrates how to use these properties properly:

HTML (ActiveX And Java Compatible) | Copy Code
--- | ---
    <script language="javascript">
    var iu = new ImageUploaderWriter("ImageUploader", 610, 500);

    iu.javaAppletCached=true;
    iu.javaAppletVersion="2.0.42.0";

    iu.writeHtml();
    </script>

To update Java version of Image Uploader

1. Copy new ImageUploader2.jar to the server instead of the old one.
2. Insert new version number to the javaAppletVersion property of the ImageUploaderWriter.
3. Make sure that javaAppletCached is true.

# Manual Update

An alternative way to update Image Uploader on client is to remove it from the browser cache manually. It may be useful if you need to downgrade the control to a lower version for some reasons.

##### ActiveX

Internet Explorer stores all downloaded ActiveX controls in the Downloaded Program Files folder inside the Windows directory. Below you will find how to remove Image Uploader from cache of Internet Explorer 6 and 7.

To remove Image Uploader from Internet Explorer 6

1. On the Tools menu of Internet Explorer, choose Internet Options.
2. Click Settings on the Temporary Internet Files box of the General tab (see the Figure 1.1):

   Figure 1.1. Step 1.

3. Click View Objects (see the Figure 1.2):

   Figure 1.2. Step 2.

4. Choose Image Uploader Control and delete it.

   Figure 1.3. Step 3.

   To delete ActiveX control from this list

   - Right-click an item and choose Remove.
     — or —
     Press DELETE key.
   - Click Yes button on the confirmation dialog.
5. Press F5 to refresh the page which contains the control. It will have Internet Explorer to update Image Uploader.

To remove Image Uploader from Internet Explorer 7

1. On the Tools menu of Internet Explorer, choose Internet Options.
2. Click Settings on the Browsing History box of the General tab (see the Figure 2.1):

   Figure 2.1. Step 1.

3. Click View Objects (see the Figure 2.2):

   Figure 2.2. Step 2.

4. Choose Image Uploader Control and delete it.

   Figure 2.3. Step 3.

   To delete ActiveX control from this list

   - Right-click an item and choose Remove.
     — or —
     Press DELETE button.
   - Click Yes button on the confirmation dialog.
5. Press F5 to refresh the page which contains the control. It will have Internet Explorer to update Image Uploader.

##### Java

Java applets are stored in the cache that is accessible through the Java control panel. Follow these steps to do it:

1. Open Java Plug-in Control Panel. Depending on the platform, it can be found in different locations:
   - Windows: Control Panel -> Java Plug-in
   - Macintosh: Applications -> Utilities -> Java -> Java1.4 Plugin Settings
   - Linux: Preferences -> Java
2. Click the Cache tab.
3. Click Clear to clear all cached applets. See the Figure 3.1 and Figure 3.2 below.

   Figure 3.1. Clearing cache on Windows or Linux.

   Figure 3.2. Clearing cache on Mac OS.

# Using Standalone Installer

Another way to update ActiveX version of Image Uploader is to use standalone installer. In this case the user installs Image Uploader as a common application. Internet Explorer is not used to carry out the installation and therefore there no problems with the browser cache.

Standalone installer can be downloaded at this location:

To install it, just run this EXE file and follow the wizard steps.

Note
You need to close all instances of Internet Explorer to make the update to come into effect.

# See Also

##### Manual

Deployment Notes
Inserting Image Uploader into Web Page

##### Troubleshooting

FAQ: Installation Problems