Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Display pdf file contents through jsp

 
Ramesh Bhagasra
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to display the pdf file contents to the web page through jsp. Currently i am trying to it using response object and setting its content type to application/pdf but the explorer does not show any output. what i have to do for initialising the pdf application and displaying the contents stored in my oracle databse as blob field. Please help me out........
 
Sona Bhavani
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
First check out if you are able to open pdf files independantly in your browser thro File > Open menu.If that works fine then you should have no problems viewing pdf files thro jsp.

Sona.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64843
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSPs are designed to return text data. For binary data such as PDF files, servlets are a much better choice.
bear
 
Ramesh Bhagasra
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can u give me some code idea for that and plz tell me can i use servlet as a bean in my jsp using usebean tag
 
Jasmine kaur
Ranch Hand
Posts: 160
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
you can try and see wheteher it works or not , well it would be better if you use servlets.
Thanks
Jasmine
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic