Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 70341 invoked from network); 13 Jul 2008 13:59:44 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 13 Jul 2008 13:59:44 -0000 Received: (qmail 5892 invoked by uid 500); 13 Jul 2008 13:59:43 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 5818 invoked by uid 500); 13 Jul 2008 13:59:43 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@cocoon.apache.org List-Id: Delivered-To: mailing list dev@cocoon.apache.org Delivered-To: moderator for dev@cocoon.apache.org Received: (qmail 63805 invoked by uid 99); 13 Jul 2008 12:14:08 -0000 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=MSGID_MULTIPLE_AT,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) From: "Christofer Dutz" To: References: In-Reply-To: Subject: AW: Client-side validation in CForms Date: Sun, 13 Jul 2008 14:13:12 +0200 Message-ID: <00ed01c8e4e1$d2bb3d80$7831b880$@dutz@c-ware.de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: Acjh1tkAcV8Qr9XQSvirbebQfjcJXADCiA7A Content-Language: de X-Virus-Checked: Checked by ClamAV on apache.org When I was working on my first attempts to do exactly what you are = trying to do (CForms using dojo 1.1 and client side validation), I ran into = exactly the same problem as you did. I too think it would be easily possible to implement client and server-side validation using dojo. Even if it would = not be possible to implement all.=20 Unfortunately the fi-output is hard-coded into the widget class implementation and no validation information is sent. Making client-side validation work, it would make it necessary to patch every single Widget class to output this validation-data, but should be easy to accomplish. I stopped my work on this, since I had doubt's anyone would be = interested in a feature like this and the thought of having to maintain patches for so many classes let me drop that idea. Chris -----Urspr=FCngliche Nachricht----- Von: Jeremy Quinn [mailto:jeremy@apache.org]=20 Gesendet: Mittwoch, 9. Juli 2008 17:17 An: dev@cocoon.apache.org Betreff: Client-side validation in CForms Hi All As you may know, I am working heavily on the revamp of Dojo on the =20 client-side of CForms. In Dojo it is possible to perform quite a lot of validation on form =20 fields. There is a partial match between the validation capabilities =20 of CForms and those of Dojo. Several people have thought in the past =20 that it would be good to have the same validation occur on both the =20 server and the client. OTTOMH, the kind of validators we could probably make work in both =20 places would be : email, length, mod10, range and regexp (plus maybe javascript, if we can sort out any context differences) ATM however, no validation information is output by the form =20 generation process. Datatypes are there (which I can initially use) =20 but no validation. So my question is, would someone volunteer to either add the =20 definition's validation tags to the output or help work out the =20 cleanest approach to adding it? Many thanks regards Jeremy