Hi There,

So I am trying to create some pages using JSP that include a call to a
servlet.  In tomcat 3.2 (at least) it is clear that I can't use the
getOutputStream() command because getWriter() has already ben called by
the JSP implementation.  Thus if I want to include output from my
serlvet into my JSP then I have to use getWriter().

This would be fine except that this means that Japanese double byte
characters aren't displayed properly.  I find that Japanese characters
will only be displayed by a a servlet using a getOutputStream() command
to generate the PrintWriter.

I have found a solution to this problem which seems to involve applying
a patch to the StaticInterceptor class

http://w6.metronet.com/~wjm/tomcat/2000/Dec/msg00085.html

I was wondering if this patch has been included in more recent versions
of tomcat, e.g. version 4.0, and if we are still in the situation of
only being able to call either the  getWriter() method or the
getOutputStream() method?

Really I would prefer not to have to use JSP at all if they are forcing
me to work with  the getWriter() method.  What I want is to be able to
include the output from one servlet in that of another.  I can do it by
opening a URLConnection to the second servlet and getting data from it,
but I would prefer to avoid having to open a socket.

I can see that the JSP implementation includes a class PageContext which
allows a JSP class to incorporate output from other JSP or servlets  -
does anyone know of a simple way to do this within servlets, i.e. to
have one servlet grab data from another servlet without having to open
an external socket?

Thanks very much in advance.

CHEERS> SAM


--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>

Reply via email to