tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jon Wingfield <jon.wingfi...@mkodo.com>
Subject Re: Specifying content type for file downloads
Date Tue, 16 Sep 2003 18:30:13 GMT
Tomcat is serving the static resource using its default servlet?
If so, try adding the mime type to the conf/web.xml file:

<mime-mapping>
   <extension>xls</extension>
   <mime-type>application/vnd.ms-excel</mime-type>
</mime-mapping>



Doug Chamberlin wrote:

> I'm using Tomcat 4.06 standalone and cannot find how to configure the 
> server to properly identify downloaded files as Excel spreadsheets. I'm 
> using links which look like:
> 
> <a href="https://webserver.com\Info\Docs\4211/SomeSpreadsheet.xls">
>   <b>SomeSpreadsheet.xls</b><br>
> </a>
> 
> When the user clicks on the link the file is being displayed in the 
> user's browser as garbage rather than having the browser display it via 
> Excel.
> 
> I cannot find how to configure the server to properly identify these 
> files as Excel spreadsheets.
> 
> Doug Chamberlin
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 




Mime
View raw message