Hello,
I am new to Struts and recently I tried an exercise which had me modularize a simple Struts application into two modules. In one of the module's Struts Config files I defined the following action mapping:
<action path="/viewSearch"
type="org.apache.struts.actions.ForwardAction"
parameter="/employee/Search.jsp"/>
whereas the book which I am using specified that I should do the following:
<action path="/viewSearch"
forward="Search.jsp"/>
Is there any difference between the 2 ? The only thing that I see here is that with the former case, you have to include the module, where the file is located, whereas in the 2nd case, the servlet for some reason knows that the "forward" parameter is relative to the current module.
Help please ? Why do I have to provide a fully qualified path in the first case ?
I am new to Struts and recently I tried an exercise which had me modularize a simple Struts application into two modules. In one of the module's Struts Config files I defined the following action mapping:
<action path="/viewSearch"
type="org.apache.struts.actions.ForwardAction"
parameter="/employee/Search.jsp"/>
whereas the book which I am using specified that I should do the following:
<action path="/viewSearch"
forward="Search.jsp"/>
Is there any difference between the 2 ? The only thing that I see here is that with the former case, you have to include the module, where the file is located, whereas in the 2nd case, the servlet for some reason knows that the "forward" parameter is relative to the current module.
Help please ? Why do I have to provide a fully qualified path in the first case ?