• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Using response.setHeader("Content-Disposition", "inline; filename=filename.csv") in post method

 
Ranch Hand
Posts: 162
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

i have huge data to be sent to the server and based on data i need to download content from server(server in turn fetches data from Database).

i tried using post method, to post huge data into server.

i am getting the content. but i am not getting the pop up.(which say "Save or Open").

when i used the response.setContentType("application/csv"); and response.setHeader("Content-Disposition", "inline; filename=TestingFile.csv"); in post method

the window appears for save or open is not appearing.

how can i archive this.

Please tell me.

Thanks In Advance,

Bennet Xavier. X.
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Bennet,

Can you try using this??

response.setHeader("Content-Disposition", "attachment; filename=filename.csv") ;

 
My first bit of advice is that if you are going to be a mime, you shouldn't talk. Even the tiny ad is nodding:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic