tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Terrence Szeto <>
Subject IE and URL rewrite causes files downloaded to lose extensions
Date Sun, 04 May 2003 18:03:16 GMT
Hi everyone.

I've done some testing, and I've noticed that IE has some difficulties
dealing with URL rewriting with file downloads.

I have setup, Tomcat 4.0.4, (tested also on Tomcat 4.1) and using IE 6.
Tomcat has been setup to use URL rewriting (no cookies), and this is where
the problem is.

If my file is named "test.exe", the URL will look something like so.;jsession=1209ad09823tasdlfkj
or something like so correct?

When IE attempts to download this file, the extension is somehow STRIPPED,
leaving the file to be saved as "test".

Is there ANY way around this?

Well, to answer my own question yes, I've been adding an additional header
and value:
"Content-disposition: attachment; filename=newName.zzz"
where newName.zzz is the file name derived from the URL. (I used a 
Filter to
run through and do all of that).

Now, an additional problem occurs.

When downloading files with multiple '.' characters, IE pads on square
brackets to the file name.

If my file name is "test1.1.exe"
IE handles this with the above implementation as: "test1[1].1.exe"

Anyone have ideas on what this is? or if anyone has solutions to this?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message