Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Help with File download

 
surendar prabu
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using File upload and download in my application.
When i try to download the file browser IE6 gives two options. open and save. when i click open it gives an error with the mmessage.

cannot find file filename in some temp location. do you want to open a ne w file. Is this because i have to set some thing in my action class? please help me on this.

regards
Surendar prabu
 
surendar prabu
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am sorry to push this post forward. But this one is urgent. If anyone has got some idea please help me with this.
 
surendar prabu
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have solved this by not setting this response header "cache-control". But now if my dowload file type is .txt i am not getting a prompt and the browser opens the file automatically on click. Can i set some response header which will force the browser to prompt before the file is being opened?

regards
Surendar prabu
 
Deepak Shah
Ranch Hand
Posts: 97
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you setting content type in header.

How are you downloading the file, is it direct link to the file or you are writing it to response (through servlet or JSP)?

I just worked with file upload/download without any problems (for different file types, XML, XLS, PDF, CSV and off course HTML)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic