Note: this is Apache-centric but read on at the end for a a potential IIS solution
Note: works only with horde 3
For Apache:
The wvHtml component of wvWare 1 can be used to generate HTML renderings of Microsoft Word documents. If wvHtml is installed, and Horde is configured to use it to view Word Documents, the msword MIME Viewer class will be invoked to generate the converted HTML document. Any embedded contents of the Word Document, specifically graphics, will be placed in the upload_tmp_dir location, as configured in your php.ini, OR, if you have defined tmpdir in horde/conf.php, that value will be used.
However, the MIME viewer class for msword returns a web page that includes image links that point to the Horde webroot. A solution some people have used is to modify the Horde or IMP code to actually write the graphics files to those locations, but this has security implications.
A more secure solution, which requires no modification to Horde, or IMP, is to leverage the Apache mod_rewrite module to rewrite wvHtml graphics links on the fly and redirect them to your temporary directory.
To do this, you must obviously have Apache installed, and the mod_rewrite module installed and enabled for your Horde installation (see the Apache mod_rewrite documentation for configuration information2)
As an example:
If:
Horde configurations:
Apache configuration:
Then your RewriteRule for Apache becomes:
RewriteRule ^/horde/imp/msword(.+) /var/www/tmp/msword$1 [L]
[# IIS ]
For IIS:
Rewriting functionality in a default configuration of IIS is limited. However, similar functionality should be attainable by using ISAPI_rewrite3. A lite version is available for free and the above syntax should work, although this author has not tested a configuration with IIS.
KMM