tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Phil Hanna <>
Subject RE: servlet include
Date Thu, 03 Aug 2000 20:18:47 GMT
out.println in your servlet is writing back to the servlet output stream, which is just going
back to the web browser.  There is no server-side JSP interpretation going on.  You don't
see it on the web page because the browser just ignores anything it can't render.  Do a view
source on the browser, and you'll see your <jsp:include> tags.

What you meant to do is request.getRequestDispatcher("Buttons.jsp").include(request, response),
which will include the JSP and merge its output with the generated HTML being sent back to
the web browser.

-----Original Message-----
From: Sebastien Payette []
Sent: Thursday, August 03, 2000 3:21 PM
Subject: servlet include

Good afternoon to all, here is my problem

I am trying to include (the output of) a jsp page into (the output of) a
servlet, without much success.

My best bet was to use this little piece of code, inside my servlet:

out.println("<jsp:include page=\"Buttons.jsp\" flush=\"true\">");
    out.println("<jsp:param name=\"TotalPage\" value=\"TotalPage\"/>");
    out.println("<jsp:param name=\"TheFolder\" value=\"TheFolder\"/>");


This looks very right to me yet still, (the output of!) my servlet skips
whatever should be
coming from the jsp page with the  <jsp:include...blablabla...>  command.
Is it something I am doing wrong? I have looked in jGuru, but my problem is
Any Ideas, suggestions?
Thanks Sebastien Payette   

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message