Title: RE: Transcoder vs. servlet
You may want to grab the servlet response OutputStream like this instead:
OutputStream out = response.getOutputStream();
TranscoderOutput output = new TranscoderOutput( out );
t.transcode(input, output);
output.flush();
output.close();
-Original
It turns out that the error is not with Batik, nor even with
Tomcat/Jakarta; it seems to be a problem with Mozilla.
If I run the servlet from IE, it works great; if I run it from Mozilla, it
fails. If I write a straight CGI script to deliver JPG files, it still
fails in Mozilla. I've posted to
I have updated the example of trying to transcode an SVG file to JPG and
send it to the client. First, I had the wrong MIME type, although fixing
that didn't help. Second, I realized that the transcoder might close the
output stream, which would be a Bad Thing for a servlet, so I have changed
it
I'm trying to transcode an SVG file (in a string buffer) to
JPG and send it out in a sevlet with this code:
==
public void headerInfo( HttpServletRequest request,
HttpServletResponse response, String contentType)
{
res