What happens in FireFox if you do this:

response.setHeader("Content-Disposition", "attachment;
filename=\"" + theFile.getName() + "\"");


The relevant spec is here: http://www.ietf.org/rfc/rfc2183.txt And for the definition of 'value' it references: http://www.ietf.org/rfc/rfc2045.txt

The filename parameter must be quoted if it contains spaces.

Jon

Mark Leone wrote:

Thanks. That's exactly what I needed, and it did the trick. Firefox browser just grabs the first non-whitespace part of the name, but in IE the entire name shows up. Thanks again.

-Mark


Chris Hyzer wrote:

Servlet Streaming file to client: Can't override
file name
    123049 by: Mark Leone



Its an HTTP header you are looking for, try this:

response.setHeader("Content-Disposition", "attachment;
filename=" + theFile.getName());

Chris




--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to