On 11 Nov 2003, at 14:15, Bruno Dumon wrote:


On Tue, 2003-11-11 at 12:47, Jeremy Quinn wrote:
Dear All

I noticed that when you use something like :

        form.getWidget ("email").setValidationError (
                new ValidationError ("validation.email.inuse")
        );

then the i18n tag output by setValidationError() looks like this:

<i18n:text catalogue="woody">validation.email.inuse</i18n:text>

which means that any custom validation errors pretty much have to be
kept in WoodyMessages which could well be inconvenient ....

Is it really necessary for Woody to set the catalogue attribute in this
situation?

Yes and no. The reason is historical: ValidationErrors were only created
by Woody classes themselves, so all their messages would come from the
woody catalogue.

OK


Now that setValidationError is a public method, it is indeed necessary
to add some more flexibility to the ValidationError class.

That would make it easier to re-use "WoodyMessages" now it's being put in the .jar.


BTW. Is there a plan to add a generic form validation message tag to
woody?
ie. not tied to a particular field widget.

As Sylvain also replied, this has been brought up already, even as recently as a couple of days ago on the user mailing list:

http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=106821138010096&w=2

I suppose you should know since you even replied to it ;-)

but I was confused as to what was happening about it ...


I've actually implemented it already but I want to clean up some other
things first before committing it.

Cool, many thanks.



regards Jeremy




Reply via email to