Thanks

Is that the only functionality of input tag or it is used for anything else.



-----Original Message-----
From: Kanoza, Douglas (NCI) [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 22, 2002 3:50 PM
To: 'Struts Users Mailing List'
Subject: RE: Help needded on Struts-config file


That's pretty much how it works.  If you look at the code in the LogonAction
in the example, they check for the existence of the database and also
compare the supplied password with the password in the database.  If there's
a problem in either case, they save the errors and redirect to the input
page.  LogonForm.validate() is only checking to see that username and
password exist - it doesn't actually check to see if they are valid.  That's
done in the LogonAction, which needs to redirect you to the input page if
the logon fails.  The code snippet below (from LogonAction.java) shows how
it's used.  The getInput() method on the ActionMapping class returns the
input page specified.

   if(!errors.empty())
    {
      saveErrors(request, errors);
      return(new ActionForward(mapping.getInput()));
    }

-----Original Message-----
From: Lundin, Michael [mailto:[EMAIL PROTECTED]] 
Sent: Friday, February 22, 2002 3:41 PM
To: 'Struts Users Mailing List'
Subject: RE: Help needded on Struts-config file

My understanding of the input is that it's a mapping to the document that
submits the form.  For this example, it's the page that presents you with
the username/password screen.

This way if there is an error, you can send the user back to the input
screen that they came from.

-----Original Message-----
From: subhendukumar mohanty [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 22, 2002 12:37 PM
To: [EMAIL PROTECTED]
Subject: Help needded on Struts-config file


Hi

One of the mapping in struts-config.xml file comes with example is as
follows

<action-mappings> 
<action path="/logon" type="org.apache.struts.example.LogonAction"
 name="logonForm"
 scope="request"
 input="/logon.jsp"
 unknown="false" validate="true" /> 
</action-mappings> 

Could anybody explain me what the "input" element means. How it is used by
controller.

Thanks,
Subhendu

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to