In general, however, you can go to actions directly as long as you supply
the required fields in the url (if any).
In the case of the struts-example, going to logon.do gives a validation
error because it was expecting the correct query string. For example:
http://localhost/struts-example/logon.do?username=foo&password=bar
Anthony
-----Original Message-----
From: Gregor Rayman [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 02, 2001 10:28 AM
To: [EMAIL PROTECTED]
Subject: Re: jsp vs do
"Anthony Martin" <[EMAIL PROTECTED]> wrote:
> This is how I understand it. A .do maps to an action then to a .jsp. If
> you link directly to a .jsp, the action never executes. Actions are
mapped
> to a .jsp in the struts-config.xml file.
>
> I'm sure there are more clear explanations to follow.
>
>
> Anthony
DO takes you to an action which needs some input from your currently
displayed from. If you don't have yet the data necessary for the
action, you cannot go to the action. In such case you can go to
HTML or JSP, which contains the input fields you can fill out and
submit to a DO action.
In the example application, the link goes to login.jsp, since it is
the place where you can enter the credentials. They are then validated
in a action (DO). You cannot go to the action directly, since you
do not have the username/password yet.
--
gR