Struts - using of action tag

C

Chris R.

Hey,

I'm new to struts and have a beginners question.


There are different ways to define an action:

<action path="/LoginForm"
type="org.apache.struts.actions.ForwardAction" parameter="page.login" /
or

<action path="/logindaten" forward="page.login"></action>

or

<action path="/logindaten"
type="de.test.LoginAction"
input="page.login"
name="loginForm">
<forward name="success" path="page.welcome" />
<forward name="failure" path="page.error" />
</action>


When do I have to use which one? When do you use the standard
ForwadAction?
Is the last definition only important if you have a formular in jsp
which you have to check
with an action?

thanks
chris
 
V

Vince

Chris said:
Hey,

I'm new to struts and have a beginners question.


There are different ways to define an action:

<action path="/LoginForm"
type="org.apache.struts.actions.ForwardAction" parameter="page.login" /

or

<action path="/logindaten" forward="page.login"></action>

or

<action path="/logindaten"
type="de.test.LoginAction"
input="page.login"
name="loginForm">
<forward name="success" path="page.welcome" />
<forward name="failure" path="page.error" />
</action>


When do I have to use which one? When do you use the standard
ForwadAction?
Is the last definition only important if you have a formular in jsp
which you have to check
with an action?

thanks
chris

If you wanna have a more simple way to use Struts then have a look at
Apache Beehive. As a new user of struts you won't have to fight your way
through the configuration of XML files

Vince
 
C

Chris R.

If you wanna have a more simple way to use Struts then have a look at
Apache Beehive. As a new user of struts you won't have to fight your way
through the configuration of XML files

Vince

Thank you, but I have to maintenance an exist project where they use
normal struts.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,744
Latest member
CortneyMcK

Latest Threads

Top