Return-Path: Delivered-To: apmail-struts-user-archive@www.apache.org Received: (qmail 22431 invoked from network); 30 Jun 2004 02:21:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 30 Jun 2004 02:21:27 -0000 Received: (qmail 87365 invoked by uid 500); 30 Jun 2004 02:21:14 -0000 Delivered-To: apmail-struts-user-archive@struts.apache.org Received: (qmail 87249 invoked by uid 500); 30 Jun 2004 02:21:12 -0000 Mailing-List: contact user-help@struts.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Struts Users Mailing List" Reply-To: "Struts Users Mailing List" Delivered-To: mailing list user@struts.apache.org Received: (qmail 87197 invoked by uid 99); 30 Jun 2004 02:21:11 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [203.89.230.163] (HELO snowwhite.hubbub.com.au) (203.89.230.163) by apache.org (qpsmtpd/0.27.1) with ESMTP; Tue, 29 Jun 2004 19:21:09 -0700 Received: from dorothy.hither.hubbub.com.au (unknown [192.168.2.34]) by snowwhite.hubbub.com.au (Postfix) with ESMTP id 9F57E7BC5C for ; Wed, 30 Jun 2004 12:20:37 +1000 (EST) Received: by dorothy.hither.hubbub.com.au with Internet Mail Service (5.5.2653.19) id ; Wed, 30 Jun 2004 12:20:37 +1000 Message-ID: <0D8D9F66A5706A4E8204F04C6D5902970274D3@dorothy.hither.hubbub.com.au> From: William Ferguson To: 'Struts Users Mailing List' Subject: RE: Using 1 Validator definition for 2 different forms? Date: Wed, 30 Jun 2004 12:20:36 +1000 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N You're right. My pet hate of the validation framework - validation should be configured on the ActionConfig instead of via the ActionConfig#path. This would provide for Mick's requirements. It would also free Strus Forms from having to extend from ValidatorForm or ValidatorActionForm in order to get some validation. William -----Original Message----- From: Joe Hertz [mailto:jhertz@speakeasy.net] Sent: Wednesday, 30 June 2004 12:14 PM To: 'Struts Users Mailing List' Subject: RE: Using 1 Validator definition for 2 different forms? Using ValidatorActionForm would result in the Validator being pointed at Actions and not forms. I don't see how that gets one validator definition... Let me ask this of Mick: Why you using two different form definitions? If they are identical, what are you hoping to accomplish by defining it twice? If you had two different actions using it, why wouldn't you just reuse one form bean definition for both of them? If that's the case, then one ValidatorForm entry in the validator is all you'd need. Of course, this ties the processing together and re-sundering it may be an issue later. Don't know how wise or unwise it would be in your case. I suspect there may be a way of getting around the problem, but I can't see it from here. > -----Original Message----- > From: William Ferguson [mailto:William.Ferguson@hubbub.com.au] > Sent: Tuesday, June 29, 2004 10:01 PM > To: 'Struts Users Mailing List' > Subject: RE: Using 1 Validator definition for 2 different forms? > > > Try extending from ValidatorActionForm instead of ValidatorForm. > > -----Original Message----- > From: Jim Barrows [mailto:jbarrows@sssc.com] > Sent: Wednesday, 30 June 2004 5:37 AM > To: Struts Users Mailing List > Subject: RE: Using 1 Validator definition for 2 different forms? > > > > -----Original Message----- > > From: Mick.Knutson@wellsfargo.com > [mailto:Mick.Knutson@wellsfargo.com] > > Sent: Tuesday, June 29, 2004 12:28 PM > > To: user@struts.apache.org > > Subject: RE: Using 1 Validator definition for 2 different forms? > > > > > > No, I mean I have a user1Form, and user2Form. > > They are identical forms as we are using Tiles to display them. > > Validator validates on form name... if they are the same form (ie same > class) and different names, > I don't think you can with 1.1. If you're using tiles to > display the same form, in 2+ different places on the same jsp > page, you don't necessarily have to have seperate form names > for each ( javascript may have issues with this though, I > don't do enough javascript to know). > > You might want to look at how ValidatorForms validate method > works, and override it in your forms to look > at the correct validation name. That's a bit of a hack though. > > > > > > > -----Original Message----- > > From: Jim Barrows [mailto:jbarrows@sssc.com] > > Sent: Tuesday, June 29, 2004 12:21 PM > > To: Struts Users Mailing List > > Subject: RE: Using 1 Validator definition for 2 different forms? > > > > > > If you're talking about masks, then you can use globals. You > > could also > > create your own custom validator, iirc 1.2 will have some > inheritance > > features, but not sure what scope yet since I'm not using 1.2. > > > > > > > -----Original Message----- > > > From: Mick.Knutson@wellsfargo.com > > [mailto:Mick.Knutson@wellsfargo.com] > > > Sent: Tuesday, June 29, 2004 12:12 PM > > > To: user@struts.apache.org > > > Subject: Using 1 Validator definition for 2 different forms? > > > > > > > > > How can I Use 1 Validator definition for 2 different forms? > > > > > > > > > --- > > > > Thanks... > > > > Mick Knutson > > > > > > > > 525 Market Street, SF, CA 94103 > > > > (415) 222-1020 > > > > Mick.Knutson@WellsFargo.com > > > > MAC A0103-223 > > > --- > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org > > > For additional commands, e-mail: user-help@struts.apache.org > > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org > > For additional commands, e-mail: user-help@struts.apache.org > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org > > For additional commands, e-mail: user-help@struts.apache.org > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org > For additional commands, e-mail: user-help@struts.apache.org > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org > For additional commands, e-mail: user-help@struts.apache.org > > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@struts.apache.org For additional commands, e-mail: user-help@struts.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@struts.apache.org For additional commands, e-mail: user-help@struts.apache.org