Antonio Petrelli wrote:
Sincerely I don't like to put js where it is not necessary.
Agreed, although I'm much less worried about this today than I was 5
years ago.
If you don't know it, Struts 1 has "LookupDispatchAction" that makes
a reverse-lookup in a resource bundle to retrieve the key and then
maps it to a method. See:
http://struts.apache.org/1.x/apidocs/org/apache/struts/actions/LookupDispatchAction.html
I did not know--thanks for pointing it out.
If the only thing different between two concrete action definitions is
the method, then both this mechanism and the one we're currently using
will work.
If you have either multiple explicit action definitions, or use wildcard
mappings, or probably other mechanisms I'm missing, this can result in a
selected action definition that simply does not appear as a valid choice
in your specification. (Because instead of selecting a new one, a
modification of the first selected one is returned.)
What I'm really arguing for is to make developers always refer to
actions by namepace&name, so that we can always select the correct valid
action specification.
We can avoid the JS requirement if we make the submit button's submitted
value complex enough to encode the names of the namespace and
actionname. Instead of returning a modification of an action mapping,
the action mapper then could completely ignore the action mapping it
would normally select and select a different one based on these two
strings. This wouldn't help with WW-2316/WW-2363/XW-595/XW-594, but it
would fix this validation problem...
-Dale
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]