aspose file tools*
The moose likes JSP and the fly likes Display pdf file contents through jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Display pdf file contents through jsp" Watch "Display pdf file contents through jsp" New topic
Author

Display pdf file contents through jsp

Ramesh Bhagasra
Greenhorn

Joined: Nov 21, 2003
Posts: 8
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

Joined: Nov 12, 2003
Posts: 6
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

Joined: Jan 10, 2002
Posts: 61766
    
  67

JSPs are designed to return text data. For binary data such as PDF files, servlets are a much better choice.
bear


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Ramesh Bhagasra
Greenhorn

Joined: Nov 21, 2003
Posts: 8
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

Joined: Nov 25, 2003
Posts: 160
Hello,
you can try and see wheteher it works or not , well it would be better if you use servlets.
Thanks
Jasmine


jasmine kaur
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Display pdf file contents through jsp