读书人

把struts的action委托给spring处理需要

发布时间: 2012-03-20 14:01:11 作者: rapoo

把struts的action委托给spring处理需要添加哪些配置?
是不是只需要在applicationContext.xml和struts.xml中加?

[解决办法]
applicationContext.xml
<bean name="/person" class="com.ssi.struts.action.PersonAction" autowire="byName" />
struts.xml
<action parameter="op" path="/person"
type="org.springframework.web.struts.DelegatingActionProxy"
validate="false">
<forward name="toIndex" path="/index.jsp" />
</action>

类似于这样吧

读书人网 >Java Web开发

热点推荐