You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Hubert Rabago <hr...@gmail.com> on 2005/08/25 17:27:12 UTC
Re: Validator hates ActionDispatcher
Whoa. Hate is a strong word. Maybe Validator just dislikes
ActionDispatcher? :)
I'm having trouble making the connection between a change in form to
ActionDispatcher not working. Then again maybe it's just me. Can you
provide more info? Like, what flavor of ActionDispatcher are you
using? What's your validation look like? What are your form values?
Action config? Favorite color? Oops, scratch that last one.
Hubert
On 8/25/05, Danny Lee <ha...@yahoo.de> wrote:
> Hi guys!
>
>
> I have a sample-application I've build together from couple of
> tutorials. It have Hibernate&Struts and works (fine) using Titles.
>
> My problem:
>
> * When I try to plug-in the Validator and change the parent of my forms
> * from "ActionForm" to "ValidatorForm" or "ValidatorActionForm" the
> * ActionDispatcher just stops to work.
>
> As result I'm allways getting back to the "input=" JSP from
> struts-config.xml
>
> As far I know, it's a well-known problem, but I haven't find any good
> looking solutions, so if someone have one... :)
>
> Cheerz
>
> Danny
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Validator hates ActionDispatcher
Posted by Hubert Rabago <hr...@gmail.com>.
Oh kay.
You kinda threw me off a bit because there's DispatchAction, and
there's ActionDispatcher:
DispatchAction (also check its Direct Known Subclasses):
http://struts.apache.org/api/org/apache/struts/actions/DispatchAction.html
ActionDispatcher:
http://struts.apache.org/api/org/apache/struts/actions/ActionDispatcher.html
:)
If they all forward to the "input" page, then it tells me that your
validations are always failing. You can trace this by overriding
validate() in your form, calling super.validate(), and checking the
return value.
If you need help understanding those validation settings, send those
rules and input values I asked for before, and who knows, maybe some
validation experts here can help you out.
Hubert
On 8/25/05, Danny Lee <ha...@yahoo.de> wrote:
> Hi Hubert,
>
> maybe you're right and they just don't like each other a little bit ;)
>
> "what flavor of ActionDispatcher are you using?"
>
> eeeh, don't know what you mean with "flavor" but I just use it for
> working with multiple buttons on my page.
>
> I have a "public class BookEditAction extends DispatchAction {...}" in
> my Action-Classes and ActionForwards in it to do my persistant stuff and
> then forward to specific JSP. Without validator it works fine.
>
> "What's your validation look like?"
>
> Basic stuff, I just checking if the Autor.name is not shorter then 3
> symbols and is not empty... (seems to work fine standing alone).
>
> "What are your form values?"
>
> Nothing specific... seems to work without big troubles...
>
> The problem really is, that all the forwards are ignored if using
> validator. Just plain redirecting to input="/jsp/bookEdit.jsp" :(
>
> thanks a lot and bye!
>
> Danny
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Validator hates ActionDispatcher
Posted by Danny Lee <ha...@yahoo.de>.
Hi Hubert,
maybe you're right and they just don't like each other a little bit ;)
"what flavor of ActionDispatcher are you using?"
eeeh, don't know what you mean with "flavor" but I just use it for
working with multiple buttons on my page.
I have a "public class BookEditAction extends DispatchAction {...}" in
my Action-Classes and ActionForwards in it to do my persistant stuff and
then forward to specific JSP. Without validator it works fine.
"What's your validation look like?"
Basic stuff, I just checking if the Autor.name is not shorter then 3
symbols and is not empty... (seems to work fine standing alone).
"What are your form values?"
Nothing specific... seems to work without big troubles...
The problem really is, that all the forwards are ignored if using
validator. Just plain redirecting to input="/jsp/bookEdit.jsp" :(
thanks a lot and bye!
Danny
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org