At 10:15 AM -0700 2/9/05, Daniel Watrous wrote:
Some googling brought me to a solution (http://www.junlu.com/msg/50968.html). It would seem that the input attribute of an action element in the configuration file must reference the logical name of a forward. With this in place the validation works fine.

This is only the case if you specifically configure your controller to do so: <controller...> <set-property property="inputForward" value="true" /> </controller>

The default behavior of Struts is to treat the value of the "input" attribute as the kind of thing which would be a legitimate value for an ActionForward's path (that is, a tile name or a path to a JSP or other thing which can be reached with RequestDispatcher.forward(...))

Joe



DW

----- Original Message ----- From: "Daniel Watrous" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Tuesday, February 08, 2005 3:37 PM
Subject: Re: Trouble with DispatchAction and ValidatorActionForm

Thanks for the advice!

I have enabled debug and found as you suggested these lines at the bottom of my file:

16:32:57,446 DEBUG RequestProcessor:787 - Populating bean properties from this request
16:32:57,459 DEBUG RequestProcessor:919 - Validating input form properties
16:32:57,460 DEBUG PropertyMessageResources:134 - getMessage(en_US,prompt.stakeName)
16:32:57,461 DEBUG PropertyMessageResources:226 - loadLocale(en_US)
16:32:57,461 DEBUG PropertyMessageResources:226 - loadLocale(en)
16:32:57,462 DEBUG PropertyMessageResources:226 - loadLocale()
..[and so on for each field]
16:32:57,479 DEBUG RequestProcessor:951 - Validation failed, returning to '/manage_stake.jsp'


Shouldn't this mean that manage_stake.jsp should be displayed? That is the last line in my log. What shall I look to now?

DW

----- Original Message ----- From: "Niall Pemberton" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Monday, February 07, 2005 4:19 PM
Subject: Re: Trouble with DispatchAction and ValidatorActionForm


You need to know what struts is trying to do. I suggest configuring the
logging to "debug" - then you should find out where its trying to go to and
what the problem is.

If validation is being performed but failing then you should see something
like...
  DEBUG Validating input form properties
  DEBUG Validation failed, returning to '/manage_stake.jsp'

If validation either isn't being performed or no errors are found, then it
should tell you where its forwarding to, something like...
  DEBUG processForwardConfig(ForwardConfig[name=?????,path=????...])

Blank pages are usually when either you haven't configured things properly,
or somethings blowing up on the page. Either way the logs should tell you.

Niall

P.S. In your struts config, you have  a "failure" forward for the mapping
that doesn't look like a proper path - although the code you say your using
doesn't show it being used...

<forward name="failure" path="error"/>



----- Original Message ----- From: "Daniel Watrous" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Monday, February 07, 2005 10:34 PM
Subject: Re: Trouble with DispatchAction and ValidatorActionForm

Thank you for the suggestion.  I tried this and am still getting only a
BLANK page with validate="true".  Are there any other ideas?
DW

----- Original Message ----- From: "Niall Pemberton" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>
Sent: Monday, February 07, 2005 2:19 PM
Subject: Re: Trouble with DispatchAction and ValidatorActionForm



 Looks to me like your missing a "/" off your input parameter....

 --->     input="manage_stake.jsp">

 Niall

P.S. don't forget to set validate back to "true".



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


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


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


--
Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com "Narrow minds are weapons made for mass destruction" -The Ex


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



Reply via email to