• 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

jsp:forward question...

 
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Guys,

I just would like some clarification, when a jsp:forward action is executed, the JSP page the contained the action is finished. Control never returns to the page.

I ask this because the I am wondering if maybe the remainder of the JSP is just ignored, or if control does not come back to it at all.

Thank you for your help.

Regards,
James
 
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Control comes back, because function calls are implemented using a stack, but the response is not affected. This is easier to test using a Servlet. Do a RequestDispatcher.forward and use a System.out.println() after that. This is not so apparent in JSP because the <jsp:forward> when converted to Servlet adds a "return", at least in Tomcat.
 
reply
    Bookmark Topic Watch Topic
  • New Topic