struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arnaud HERITIER" <aherit...@sopragroup.com>
Subject RE: 2 submit buttons with different action
Date Tue, 24 Dec 2002 16:14:27 GMT
In this page :
http://jakarta.apache.org/struts/userGuide/dev_validator.html

the doc says :

The most fundamental change is the ability to conditionally require
validator fields based on the value of other fields. It allows you to define
logic like "only validate this field if field X is non- null and field Y
equals "male".

I think it is possible to do what you want with the validator but don't know
how.


> -----Message d'origine-----
> De : Arnaud HERITIER [mailto:aheritier@sopragroup.com]
> Envoye : mardi 24 decembre 2002 17:07
> A : 'Struts Users Mailing List'
> Objet : RE: 2 submit buttons with different action
>
>
> Sorry but I don't use yet the DynaValidationForm, so I don't
> know how to
> configure it :-(
>
> I don't know how is defined a validation.xml file but it is
> not possible to
> define dependencies between several fields ??
>
> If this field equals "bidule" then this other field should be
> equal to truc
> ???
>
> If it doesn't exist, it could be a good enhancement to
> propose I think.
>
> Arnaud
>
> > -----Message d'origine-----
> > De : Ashish Kulkarni [mailto:kulkarni_ash1312@yahoo.com]
> > Envoye : mardi 24 decembre 2002 16:53
> > A : Struts Users Mailing List; aheritier@sopragroup.com
> > Objet : RE: 2 submit buttons with different action
> >
> >
> > Hi,
> > I m using DynaVaidationForm so struts automatically
> > checks for the validation depending upon the
> > defination in validation.xml
> > is there a way out by using DynaValidationForm
> >
> > Ashish
> > --- Arnaud HERITIER <aheritier@sopragroup.com> wrote:
> > > you can define a property in your form bean with a
> > > different value if you
> > > use one button or the other.
> > >
> > > In your validation method you test this property to
> > > verify if you check the
> > > others fields or not.
> > >
> > > Arnaud
> > >
> > > > -----Message d'origine-----
> > > > De : Ashish Kulkarni
> > > [mailto:kulkarni_ash1312@yahoo.com]
> > > > Envoye : mardi 24 decembre 2002 16:29
> > > > A : Struts Users Mailing List
> > > > Objet : 2 submit buttons with different action
> > > >
> > > >
> > > > Hi,
> > > >
> > > > I have 2 buttons on one jsp, one is submit button
> > > and
> > > > the other is back. I want to use only one action
> > > form
> > > > to handle both the events, I am using
> > > > DynaValidatorForm.
> > > > So the problem i amfacing is, the fields get
> > > validated
> > > > even if i press the back button,
> > > > Is there a way to make sure that the validation
> > > occurs
> > > > only when i press submit button
> > > >
> > > >
> > > >
> > > > =====
> > > > A$HI$H
> > > >
> > > > __________________________________________________
> > > > Do you Yahoo!?
> > > > Yahoo! Mail Plus - Powerful. Affordable. Sign up
> > > now.
> > > > http://mailplus.yahoo.com
> > > >
> > > > --
> > > > To unsubscribe, e-mail:
> > > >
> > > <mailto:struts-user-unsubscribe@jakarta.apache.org>
> > > > For additional commands, e-mail:
> > > > <mailto:struts-user-help@jakarta.apache.org>
> > > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > > <mailto:struts-user-unsubscribe@jakarta.apache.org>
> > > For additional commands, e-mail:
> > > <mailto:struts-user-help@jakarta.apache.org>
> > >
> >
> >
> > =====
> > A$HI$H
> >
> > __________________________________________________
> > Do you Yahoo!?
> > Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
> > http://mailplus.yahoo.com
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:struts-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:struts-user-help@jakarta.apache.org>
>
>
> --
> To unsubscribe, e-mail:
> <mailto:struts-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:struts-user-help@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message