I have a legacy application that, at some point, generates the following code in one of its pages:
window.location.href = "http://localhost:8080/myApplication/manuals/charts.xls";
When Mozilla sees this, it opens a download dialog with "open with...\save as..." options.
IE (v7 and v8) does not open a dialog. It takes the file and just renders it in the page, like some HTML; but it's a binary file, so all you see is garbage on the screen.
Has anyone encountered this before?
EDIT1: This works on some IE browser but not on all. I am thinking a configuration issue with IE. Also, for .ppt
and .doc
files it works, the issue is just for .xls
files.
EDIT2: Even if I place a link in the page like:
click <a href="http://localhost:8080/myApplication/manuals/charts.xls">here</a> for the XLS
it won’t display the dialog box when I click on it. It just gets written in the page.