How can I set the welcome page to a struts action?

后端 未结 15 1979
天涯浪人
天涯浪人 2020-11-29 20:15

I have a struts-based webapp, and I would like the default \"welcome\" page to be an action. The only solutions I have found to this seem to be variations on making the welc

15条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-11-29 21:15

    This worked fine for me, too:

    
    MyAction.action
    
    

    I was not able to get the default action to execute when the user enters the webapp using the root of the web app (mywebapp/). There is a bug in struts 2.3.12 that won't go to the default action or use the welcome page when you use the root url. This will be a common occurrence. Once I changed back to struts 2.1.8 it worked fine.

提交回复
热议问题