Struts2 / Struts1 action calls

为君一笑 提交于 2019-12-06 12:03:51

You have thought in the wrong direction. There's a Struts1 plugin in Struts2 that actually wraps the Struts1 action. So, the code will look like

<action name="contactsList" class="org.apache.struts2.s1.Struts1Action">
  <param name="className">com.mycompany.myapp.ContactsListAction</param>
  <result>contactsList.jsp</result>
</action>

To your question the Struts2 return result that either redirect or dispatch to the servlet even if your action doing nothing. You could do anything with the browser but Struts will accept requests until you map it to the url where it's responsible to react on the browser requests.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!