Alex Rivera | Logout

How do you get a spreadsheet to open Excel instead of a browser window?

Asked 2008-09-23T12:26:33.340
10

If you call javascript window.open and pass a url to a .xls file it open on some machines in the browser window. How can you force it into Excel?

Edit
Report

1 Answer

1

If it's just a static file, and you're using Apache on Linux, check for a file called /etc/mime.types, and ensure that it has the following line in there to associate the .xls file extension with the correct MIME type:

application/vnd.ms-excel    xls

I'm guessing the location of that file might vary across systems, but it's in /etc/mime.types on my server which is running RHEL4.

answered 2008-09-23T12:45:34.417

Your Answer