ok, it appears that this forum is not a good place to post. so that i don't look like a complete idiot, i thought i'd post a reply. in case anyone is experiencing the same problem, i semi-solved it:
there is a bug in the current struts 1.2.4 release. see the following links:
http://issues.apache.org/bugzilla/show_bug.cgi?id=32401 and
http://issues.apache.org/bugzilla/show_bug.cgi?id=21760 the problem is in org.apache.struts.validator.Resources.getArgs and Resources.getMessageResources (in same class). The validateXXX methods in org.apache.struts.validator.FieldChecks use Resources.xxx methods as helpers. because you can define your own validators in validator-rules.xml, this is a hook into solving the problem.
i got it to work by defining my own MyFieldChecks.validateXXX methods, and creating new MyResources.xxx methods.
if you're trying to do this, it's really quite simple. overload MyResources.getArgs(...), adding an HttpServletRequest argument to the parameter list. Also overload MyResources.getMessageResources(...), adding a String argument to the paramter list.
modify your code in MyResources.getActionMessage(HttpServletRequest, ValidatorAction, Field) to call the new overloaded getArgs, and in that method, when you come to this line:
if (args[i].isResource()) {
... check to see if args[i] has a bundle:
if (!GenericValidator.isBlankOrNull(args[i].getBundle())) {
... and if it does, get the resources for that bundle:
messagesSaver = messages;
messages = getMessageResources(request, args[i].getBundle());
}
... then use the standard helper method to get the message:
argMessages[i] = getMessage(messages, locale, args[i].getKey());
... afterward, be sure to reset messages to its original value:
messages = messagesSaver;
you will also of course need to update your validator-rules.xml file to use your new MyFieldChecks.validateXXX methods.