You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Paul Benedict <pb...@apache.org> on 2008/07/12 21:15:31 UTC
CodeBehind and index action?
Does the CodeBehind plugin allow me to specify a default action for a
directory? So that way I can just do /dir instead of /dir/index.action? If
not, how can I do it? I want any directory to go invoke index.action
I am using Struts 2.0.11
Paul
Re: CodeBehind and index action?
Posted by Jeromy Evans <je...@blueskyminds.com.au>.
Paul Benedict wrote:
> Does the CodeBehind plugin allow me to specify a default action for a
> directory? So that way I can just do /dir instead of /dir/index.action? If
> not, how can I do it? I want any directory to go invoke index.action
>
> I am using Struts 2.0.11
>
> Paul
>
No, that's a feature of the Convention plugin in 2.1.x though.
A simple alternative is to write a custom ActionMapper that extends the
default and sets the action name to index if there was no other match
and no extension.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org