See the description for the 'action' attribute at http://jakarta.apache.org/struts/struts-html.html#form
In short, Struts automatically append '.do' to the action attribute ('/login') of <html:form>. This is the part the doco hasn't explained in details. At 11:42 am 31-10-2001 +0000, you wrote: >Hello > > > >I am trying to understand Struts. I have read the following part of the >documentation relating to the Struts example application that comes with the >v1.0 binary download. > >************************ > >LogonAction.java >The initial JSP submits its form to logon.do. If you check the servlet >mappings in the example's web.xml you will see that requests for *.do files >are directed to the Struts "action" servlet (an instance of ActionServlet). >In the example, the ActionServlet refers to struts-config.xml for its own >mappings (among other things), which is where we find the reference to >logon.do: > <!-- Process a user logon --> <action path="/logon" >type="org.apache.struts.webapp.example.LogonAction" name="logonForm" >scope="request" input="/logon.jsp" > </action> > >and a form bean to go with the "logonForm" action: > ><!-- Logon form bean --> <form-bean name="logonForm" >type="org.apache.struts.webapp.example.LogonForm" /> > > In the action mapping, the path property tells the ActionServlet to forward >a request for logon.do to the LogonAction object. The input property tells >the LogonAction object where it can pass control to get information from the >user. > >************************ > >The problem is as far as I can see, the initial JSP (logon. jsp) does not >submit its form to logon.do it actually uses /logon and since /login is not >mapped in the web.xml file I can't work out how the flow control works. > >Is this part of the documentation wrong, or I am I missing something? > >If you think its wrong, can you tell me how it should read or more >importantly how the control flow actually works? > >Thanks -- John Yu Scioworks Technologies e: [EMAIL PROTECTED] w: +(65) 873 5989 w: http://www.scioworks.com m: +(65) 9782 9610 Scioworks Camino - "Rapid WebApp Assembly for Struts" -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>