Re: Usage of include or forward in Action definition

2001-05-30 Thread Craig R. McClanahan



On Thu, 3 May 2001, James Howe wrote:

 Could someone explain a little more about when you would want to use either 
 the include or forward attributes of the action tag (used in 
 struts-config.xml) instead of the type attribute?  An example or two 
 would go a long way to clarifying when and why someone might want to use 
 either include or forward.
 
 Thanks.
 
 

The basic idea is that you might have existing logic, implemented as a
servlet, that you want to integrate into a Struts-based application.  You
can still take advantage of the automatic form bean handling and so on,
but then utilize the existing servlet instead of (or in addition
to) writing an Action.

A more radical use that I'm experimenting with a little is the idea of
scripting an action -- in a JSP page (?!?!?!).  These pages would not
actually create any output -- but they would allow application developers
who are not heavy duty Java programmers to create Actions out of existing
custom tag libraries (including our very own bean and logic tags).  Such a
business logic page would then forward to a different JSP page for the
presentation, just as you would from an Action that is coded in Java.

Craig McClanahan






Usage of include or forward in Action definition

2001-05-03 Thread James Howe

Could someone explain a little more about when you would want to use either 
the include or forward attributes of the action tag (used in 
struts-config.xml) instead of the type attribute?  An example or two 
would go a long way to clarifying when and why someone might want to use 
either include or forward.

Thanks.