This "weird" problem was being caused because my integration with ACEGI.
On 5/15/07, Juan Maya <[EMAIL PROTECTED]> wrote:
I think i am starting to be annoying but i found out that inside a component the first form will not execute server side validation. In the following code the the validators will be executed fine. <t:form> </t:form> <t:form> <input t:type="TextField" t:id="username" t:validate="required,email"/> <t:errors/> <input type="submit" value="Send" class="submit"/> </t:form> However the validators will not be executed if i change the code to look like this: <t:form> <input t:type="TextField" t:id="username" t:validate="required,email"/> <t:errors/> <input type="submit" value="Send" class="submit"/> </t:form> <t:form> </t:form> Could somebody please check this? On 5/15/07, Juan Maya <[EMAIL PROTECTED]> wrote: > I found out my problem. For some reason i added an id parameter to the form > component and this was causing the problem. > Sorry :S > > > On 5/15/07, Howard Lewis Ship <[EMAIL PROTECTED]> wrote: > > > > Really? That's a surprise and a bug if true. > > > > On 5/15/07, Juan Maya <[EMAIL PROTECTED]> wrote: > > > > > > But none of the basic implementors are executing server side validation. > > > (i > > > tried required and minLength) > > > > > > On 5/15/07, Howard Lewis Ship <[EMAIL PROTECTED]> wrote: > > > > > > > > Yes, but the magic is built into the validator implementation. > > > > > > > > On 5/15/07, Juan Maya <[EMAIL PROTECTED]> wrote: > > > > > > > > > > I Howard, > > > > > Thank u for the answer. That was what i did. I followed the pattern > > > but > > > > i > > > > > didn't see how to add easily new Javascript. I could modify > > > tapestry.js > > > > > but > > > > > i think that's not the best way to do it. > > > > > > > > > > I thought the validators were able to execute server and client side > > > > > validation. According to the documentation "Tapestry excels at > > > creating > > > > > forms and validating input. Input validation is declarative, meaning > > > you > > > > > simply tell Tapestry what validations to apply to a given field, and > > > it > > > > > takes care of it on the server and (once implemented) on the client > > as > > > > > well." > > > > > > > > > > Thanks > > > > > > > > > > On 5/15/07, Howard Lewis Ship <[EMAIL PROTECTED]> wrote: > > > > > > > > > > > > On 5/14/07, Juan Maya <[EMAIL PROTECTED]> wrote: > > > > > > > > > > > > > > Hi all, > > > > > > > I am trying to contribute a new Email Validator that would > > check > > > if > > > > > an > > > > > > > email is valid or not. > > > > > > > > > > > > > > To do it i created a class Email that implements Validator<Void, > > > > > > Object>. > > > > > > > Then i contributed the Validator in My AppModule: > > > > > > > public static void > > > > > > > contributeFieldValidatorSource(MappedConfiguration<String, > > > > Validator> > > > > > > > configuration){ > > > > > > > configuration.add(Email.NAME, new Email()); > > > > > > > } > > > > > > > > > > > > > > My question are: > > > > > > > 1. How could i add a client side validation for my email > > > validation? > > > > > > > > > > > > > > > > > > > > > > > > Follow the pattern present in the existing validators. > > > > > > > > > > > > > > > > > > 2. I disabled js in my browser and none of the basic Validators > > > > > > (required, > > > > > > > minLegth, etc) worked . Am i a missing something obvious? > > > > > > > > > > > > > > > > > > > > > > > > If JavaScript is disabled, then you don't get client side > > > validation, > > > > > > since > > > > > > it requires JavaScript. That's why you always re-check on the > > > server. > > > > > > > > > > > > > > > > > > Thanks > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > Howard M. Lewis Ship > > > > > > TWD Consulting, Inc. > > > > > > Independent J2EE / Open-Source Java Consultant > > > > > > Creator and PMC Chair, Apache Tapestry > > > > > > Creator, Apache HiveMind > > > > > > > > > > > > Professional Tapestry training, mentoring, support > > > > > > and project work. http://howardlewisship.com > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > Howard M. Lewis Ship > > > > TWD Consulting, Inc. > > > > Independent J2EE / Open-Source Java Consultant > > > > Creator and PMC Chair, Apache Tapestry > > > > Creator, Apache HiveMind > > > > > > > > Professional Tapestry training, mentoring, support > > > > and project work. http://howardlewisship.com > > > > > > > > > > > > > > > -- > > Howard M. Lewis Ship > > TWD Consulting, Inc. > > Independent J2EE / Open-Source Java Consultant > > Creator and PMC Chair, Apache Tapestry > > Creator, Apache HiveMind > > > > Professional Tapestry training, mentoring, support > > and project work. http://howardlewisship.com > > >
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]