Okay, this sounds like the validation plugin (I've written) could be useful: http://bassistance.de/jquery-plugins/jquery-plugin-validation/
You'd add a very small script to the head: $(function() { $("#formid").validate() }); And then create inline rules based on the validation behaviour. There are two options for those: Either classes and (custom attributes) or metadata (which requires an additional plugin). I think classes/attributes work really well and result in readable HTML, though depending on the rules in use, it won't validate. For example, to make an input required and an email address: <input class="required email" name="... /> For an optional input with min and max length: <input minlength="5" maxlength="15" /> For an input with min/max value: <input min="5" max="10" /> Those are actually attributes defined by HTLM5 (http://www.whatwg.org/specs/web-apps/current-work/#the-min-and-max-attributes). I've tried to keep it close to specs where possible and already existing. The thing is: generating those classes/attributes with Wicket is really easy and already works fine in a lot of projects. Let me know if invalid HTLM isn't acceptable, and I'll detail the alternatives. Jörn On Sat, Oct 4, 2008 at 4:39 PM, Jeremy Thomerson <[EMAIL PROTECTED]> wrote: > Basically, where you would normally call: > Formcomponent.add(IValidator), > You could now add a behavior. In my behavior, on bind I add the server-side > equivalent validator. Then in renderHead, I add some onLoad JS that adds the > component to a JS array of components to be validated on form submit. > > Let me get a little more of the basic started, and then I would REALLY > welcome the help! Maybe tomorrow night or Monday I can get a wicketstuff > project started for it... > > The help will be great - my JS fu is rusty! > > Jeremy Thomerson > http://www.wickettraining.com > -- sent from a wireless device > > > -----Original Message----- > From: Jörn Zaefferer =F6rn_Zaefferer _ <[EMAIL PROTECTED]> > Sent: Saturday, October 04, 2008 5:50 AM > To: users@wicket.apache.org > Subject: Re: Client side validation behaviors - already started? > > What approach for client-side validation are you looking for? I may be > able to help with that. > > Jörn > > On Fri, Oct 3, 2008 at 5:50 AM, Jeremy Thomerson > <[EMAIL PROTECTED]> wrote: >> I've been thinking of trying to create some behaviors that combine the >> standard server-side validation with client-side validation. I just wanted >> to check to see if anyone knew of something like this already started. I >> don't want to duplicate work already done. >> >> Thanks, >> >> -- >> Jeremy Thomerson >> http://www.wickettraining.com >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >