• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

RequestDispatcher.include

 
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What should be the result of a.jsp?
In Tomcat, the output was
bc
<br>
and In Resin, the output was
b
<br>
c
I thought that the output should be the one returned by Resin but why did Tomcat return such output?
---- a.jsp code ----
<%
RequestDispatcher rd = application.getRequestDispatcher("/rd/b.jsp");
rd.include(request, response);
%>
<br>
<%
rd = application.getRequestDispatcher("/rd/c.jsp");
rd.include(request, response);
%>
---- b.jsp code ----
b
---- c.jsp code ----
c

Thanks,
Jerson
 
Ranch Hand
Posts: 104
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not sure why, but I would say tomcat's behaviour is incorrect.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic