tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Markus Kirsten <>
Subject Re: File download with Tomcat 4.0.2
Date Sat, 01 Jun 2002 08:11:35 GMT
Hi Alex,
I think that's actully up to the browser to determinate wheter the 
browser should display the data, if a helper application should do so or 
if the user should be prompted to download the file without displaying 
or executing it. So, in other words, what you need to do is to say on 
the page which links to the file that if the browser just displays the 
data you need to press [ALT] on Mac while downloading (and is it [SHIFT] 
on Windows?). However if your userbase i pretty constant like on an 
intranet you could send out instructions that files with the extension 
fls shouldn't be displayed in the browser but instead should the user be 
prompted for download (or maybe even more convinient - opened in the 
right application).


On Friday, May 31, 2002, at 11:34 PM, Alex Roussev wrote:

> Hello,
>  How do I force Tomcat to serve a file as a download, instead of 
> displaying it in the browser?
>  For example, if I have an href pointing to a  filename with extention 
> exe and I click on the href
>  within a browser it will prompt me to save this  file.
> So basically, I want to do this with another file extention ( fls ).  
> However,  when I click on the href Tomcat displays the contents of this 
> file in the browser.  Is there something I need to set up the web.xml 
> file?
> Do I need to define another  <mime-mapping> ?
> Thank you,
> Alex
> ---------------------------------
> Do You Yahoo!?
> Yahoo! - Official partner of 2002 FIFA World Cup

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

View raw message