I think I have a good understanding of how to incorporate STRUTS in my
JSPs. The problem I'm having is with the Action Servlet Mapping. My goal
is to keep my JSPs small in size so I have one (session) bean that is
populated from form properties from eash JSP (a total of 5 in all). My
web.xml has the Servlet Mapping defined as:
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>/webapp/*.do</url-pattern>
</servlet-mapping>
All my form action attributes have ".do" extension and
the same form bean name. The action.xml is configured as:
<action-mappings>
<!-- Global Forward Declarations -->
<forward
name="introduction"
path="/SpcIntroduction.jsp"/>
<!-- Process test -->
<action path="/introduction"
actionClass="request.spc.SpcRequestAction"
formAttribute="spcRequest"
formClass="request.spc.SpcRequestForm"
inputForm="/SpcIntroduction.jsp">
<forward name="next"
path="/SpcInformation.jsp"/>
</action>
<action path="/information"
actionClass="request.spc.SpcRequestAction"
formAttribute="spcRequest"
formClass="request.spc.SpcRequestForm"
inputForm="/SpcInformation.jsp">
<forward name="next"
path="/SpcSchedule.jsp"/>
</action>
<action path="/schedule"
actionClass="request.spc.SpcRequestAction"
formAttribute="spcRequest"
formClass="request.spc.SpcRequestForm"
inputForm="/SpcSchedule.jsp">
<forward name="next"
path="/SpcMessage.jsp"/>
</action>
<action path="/message"
actionClass="request.spc.SpcRequestAction"
formAttribute="spcRequest"
formClass="request.spc.SpcRequestForm"
inputForm="/SpcMessage.jsp">
<forward name="next"
path="/SpcConfirmation.jsp"/>
</action>
<action path="/confirmation"
actionClass="request.spc.SpcRequestAction"
formAttribute="spcRequest"
inputForm="/SpcConfirmation.jsp"
formClass="request.spc.SpcRequestForm">
<!--forward name="next"
path="/SpcConfirmation.jsp"/-->
</action>
</action-mappings>
When I run with this configuration locally using Tomcat 3.2.1,
everything seems to work okay when going to the "next" page
(yet the browser always shows the ".do" name of the form). But
when I transfer the pages and this configuration to my Servlet hosting
website, the server can never find the "next" page and can't
resolve finding "introduction.do".
I am missing something here. Please give me some expert advice on how
to make this work properly both locally and live, and how to make the
".jsp" appear in the browser URL area for all my pages.
TIA
- Re: Missing Something Tim Sheridan
- Re: Missing Something Craig R. McClanahan
- Re: Missing Something John Raley
- Re: Missing Something Craig R. McClanahan

