views:

7

answers:

1

I have placed a .MSI-file in the folder C:\JBoss\server\default\deploy\install.war on my web server which is running Jboss. The idea is that web page visitors should be able to download the file by visiting http://example.com/install/file.msi.

Now, if a user goes to to this URL with his web browser, instead of getting a "Do you want to download this file"-dialog, the contents of the MSI file is shown directly in the web browser window (in other words, the binary data).

I installed Fiddler and have saw that Jboss sends no Content-Type header when accessing the file. If I access an .exe file in the same directory, Jboss sends a Content-Type with value "application/octet-stream".

How do I configure Jboss to send the same content-type for the .MSI file type? I'm guessing there's some config file I need to add this to?

A: 

Found the answer using Google. Add a MIME type mapping to web.xml.

martinnitram

related questions