J,
I was able to remove all refrencies to the session from my servlet.
I was also able to view the image by calling the servlet directly in
a browser. Last of all I was able to save this viewed image to a
file. I then used it directly in a pdf and it worked. Why would FOP
be able to determine the image type from a file and not from my servlet?
Nathan
On Jun 11, 2005, at 2:17 PM, J.Pietschmann wrote:
Nathan Maves wrote:
I have a servlet (struts) that returns a generated chart.
What is the best/simplest way to get this into a pdf?
...
<fo:external-graphic src="url(http://localhost:
8080/ ScoreCard/View/MetricChart.do)"/>
In general, this should work.
...
[ERROR] Could not load external SVG: Premature end of file.
[ERROR] Error while creating area : No ImageReader for this type
of image (http://localhost:8080/ScoreCard/View/MetricChart.do)
The image reader was't able to determine the image type,
or got some other problem. Check the instructions in the FAQ
http://xml.apache.org/fop/faq.html#graphic-not-displayed
in particular:
- Check whether you can display the image in a browser
- Download a generated image into a file and try to use it
from this file (i.e. check whether the problem is with the
content of the image itself or whether it has somethiing to
do with being loaded via HTTP).
- If the problem is the image itself, try to open it in another
graphics viewer in order to get more information about what
might be wrong
- If the problem is with image delivery, well, fix them. A missing
session cookie is a likely candidate for the cause.
J.Pietschmann
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]