cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christoph Hermann <christoph.herm...@tu-clausthal.de>
Subject Re: [CForms] - Design question
Date Tue, 26 Jul 2005 13:50:50 GMT
Johannes Becker schrieb:

Hello,

> I've got a form which holds two date and an integer field.
> Either the two date fields or the integer field has to be filled out.
> If the date fields are filled out, the first date has to be 'smaller or
> equal' than the second date.
> 
> Question 1.:
> How do achieve the: "Either the two date fields or the integer field has
> to be filled out".

i'd use a combination of "empty()" and "and" and "or"

> Question 2.:
> How do achieve the: "The first date has to be 'smaller or equal' than
> the second date".

You have to use some additional validation (this should be possible
using the xreporter syntax).
See http://cocoon.apache.org/2.1/userdocs/forms/validation.html#Reference
and
http://cocoondev.org/xreporter/docs/core/91.html

> Question 3.:
> After success I want to call either function aaa (if dates were filled
> in) or function bbb (if integer was filled in). How can I manage this?

I would use flowscript for this.

HTH
Christoph

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message