Images Missing

By: jper - jper
Images Missing
2002-12-18 03:21
I implement the web app example.
i do not use sessions, and do not use the image.jsp page the resulting html returned to the screen is missing the px image.
Any ideas??




By: Teodor Danciu - teodord
RE: Images Missing
2002-12-18 05:15

Hi,

You don't see the images exactly because you
do not use http sessions and the image.jsp.
Where should the browser load the images from?

The only other solution I see is to output the HTML
content into files on disk and redirect the browser
to them.
This is how things worked in previous versions of
the "webapp" sample, but had little success.

Thank you,
Teodor





By: jper - jper
RE: Images Missing
2002-12-18 06:37
Cheers,

When i save the files as you suggested to disk in pdf/html format all is well and images are found.

I am hoping to allow my college lecturer to view the report and then give him the option to save to the different formats.dont really want to me creating files on the server until the user wishes to.
Am i depend on this pixel when the report is outputted in html to the screen.

Also will there be a problem if two users try to generate a pdf at the same time but with different data. i.e will the jprint file be locked by one and if one user has the pdf open how can the other create one.









By: Teodor Danciu - teodord
RE: Images Missing
2002-12-18 07:14

Hi,

Well, you see?
:)
This is why you have to use http sessions, so that
you can store things in memory and do not
generate files on disk.

With sessions, concurent users will be isolated
from each other.

I hope this helps.
Teodor





By: jper - jper
RE: Images Missing
2002-12-18 07:23
Good Point.
But there is a limited amount i can store in the session, does it still mean that if the user wants to create a report the jrprint file may be in use or the pdf file may be open this will cause problems.

?
thanks for the replys




By: Teodor Danciu - teodord
RE: Images Missing
2002-12-18 07:44

Hi,

When generating PDF, you don't have to store
anything.
PDF content can be generated and sent over
the network on the fly, using output streams.
This is how the "webapp" works.

But with HTML output, things are different.
The images have to be stored somewhere
(disk or memory), because you cannot send them
embedded in the HTML content itself.

I hope this helps.
Teodor





By: jper - jper
RE: Images Missing
2002-12-18 08:21
Cheers
Will look into this image problems abit more.
The web app example is very helpful. however when
Finally, Can you think why the pdf file will not open in the browser but will only allow me save it and a default name of pdf.jsp is what appears in the save box.

Thanks for all your reply's




By: jper - jper
RE: Images Missing
2002-12-18 08:03
Cheers
Will look into this image problems abit more.
The web app example is very helpful. however when
Finally, Can you think why the pdf file will not open in the browser but will only allow me save it and a default name of pdf.jsp is what appears in the save box.

Thanks for all your reply's




By: Teodor Danciu - teodord
RE: Images Missing
2002-12-19 00:06

Hi,

Here you might find the solution:

https://sourceforge.net/forum/message.php?msg_id=1680060

I hope this helps.
Teodor





By: jper - jper
RE: Images Missing
2002-12-19 04:04
A final note on the image problem.
Why are they used is it for padding?
I have gone back to session and it picks up the images fine. I was hoping not to have to use a session can you think of how i might point the images uri to an images folder.

When i displayed the html outputted report and included in a web page the padding bought the report down the page a bit. is it possible to stop this.

Have read the ultimate guide helpful on alot of issues.





By: Teodor Danciu - teodord
RE: Images Missing
2002-12-19 09:15

Hi,

Have you tried the IMAGES_URI parameter
of the JRHtmlExporter?
Make it point to a directory that already stores
the "px" image.

I hope this helps.
Teodor





By: robert casson - rcasson
RE: Images Missing
2002-12-31 13:19
Teodor, I having a similar html export problem with the images path not being resolved in a web application in which the browser is the client. Basically, in a web handler I fill the report and export it to an html file, then return the path of the html file so that the web application will display the report directly. Redirecting the browser is not a known solution (running Apache Tomcat).I looked at JRHtmlExporter and don't see any IMAGES_URI parameter, nor is it in The Utimate Guide. Any guidance is most appreciated. Thanks




By: Teodor Danciu - teodord
RE: Images Missing
2003-01-02 02:03

Hi,

You need the 0.4.4 version of the library.
There is a complete updated "webapp" sample
there. No need for html files on disk and browser
redirect anymore.
The guide was not yet updated.

Thank you,
Teodor
2006 IR Open Dicussion's picture
Joined: Aug 10 2006 - 3:24am
Last seen: 17 years 1 month ago

0 Answers:

No answers yet
Feedback