> If you did that, how would it know whether to use the 'path' or the
'name' to look up the validation rules?

Wouldn't it alway use the 'name' it looked up from the given action ? Is there a time it would ever use the 'path' ? I guess I don't understand ?

What if you were using ValidatorActionForm/DynaValidatorActionForm instead of ValidatorForm/DynaValidatorForm? Then the server side validation rules are looked up based on the path, not the name. With the form classes, this can be encapsulated cleanly in a way that is invisible in the struts-config, (and even more so thanks to Niall's recent patch) But that's invisible to the html:javascript tag.


By the way, the names for those classes have to be one of the most confusing things about Struts; I only just really grokked the difference in the last couple of months, and most of the developers I work with are still kind of fuzzy about it.

There is something attractive about somehow involving the ActionForm class in the client side validation, but that seems kind of challenging. Maybe for Struts 2.0... ?
--
Joe Germuska [EMAIL PROTECTED] http://blog.germuska.com "Imagine if every Thursday your shoes exploded if you tied them the usual way. This happens to us all the time with computers, and nobody thinks of complaining."
-- Jef Raskin


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to