[Html-widget] Either/Or validation
Will Hawes
wdhawes at gmail.com
Tue Feb 27 15:32:36 GMT 2007
Yes, thinking about it that would probably work - an Any constraint
for the select box and one of the text fields, plus an AllOrNone for
all the text fields. Good call, thanks. ;)
On 27/02/07, Mario Minati <mario at minati.de> wrote:
> Will Hawes schrieb:
> > Probably I've missed something, but how do you go about implementing
> > either/or validation?
> >
> > I have a select box and a set of text fields and require either a
> > selected option in the select box or the text fields to be filled in,
> > but not both. It occurred to me to use ::Constraint::Callback, but
> > this doesn't appear to provide access to the values of other fields.
> >
> > Writing a custom constraint won't be a problem, just making sure I've
> > not overlooked an existing way to do this.
> >
> > Thanks, Will
> >
> > _______________________________________________
> > Html-widget mailing list
> > Html-widget at lists.rawmode.org
> > http://lists.rawmode.org/cgi-bin/mailman/listinfo/html-widget
> >
> What about HTML::Widget::Constraint::Any?
>
> Greets,
> Mario
>
> _______________________________________________
> Html-widget mailing list
> Html-widget at lists.rawmode.org
> http://lists.rawmode.org/cgi-bin/mailman/listinfo/html-widget
>
More information about the Html-widget
mailing list