![]() |
Sponsored Link •
|
Advertisement
|
Advertisement
|
This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.
Message:
> > I had written following Java Download Servlet and which is working fine with Netscape but not with Internet Explorer. Problem with Internet Explorer is that while Downloading file, Instead of taking File Name it takes Servlet Name for file Downloading... > > Thank you very much in advance. > > bhaskar > > import java.io.*; > > public class fileDownload extends HttpServlet { > > public void doGet(HttpServletRequest req ,HttpServletResponse res) > > public void doPost(HttpServletRequest req ,HttpServletResponse res) > > res.setContentType("application/x-filler"); > > try { > > res.setHeader("Content-Disposition","attachment; filename=\"" + downloadFile + "\";"); > > ServletOutputStream stream = res.getOutputStream(); > > BufferedInputStream fif = new BufferedInputStream(new FileInputStream(downloadFile)); > > catch(Exception e) { > > finally { > > } catch (Exception ignore) {} > > } > > I have got the same problem! I think it is not a general problem with the Internet Explorer. In my opinion it is a special problem with the Internet Explorer 5.5 SP1. With other Versions it seems to work fine. > Nevertheless I was not able to solve this problem! Has anybody a solution? > regards Oliver
Replies: |
Sponsored Links
|