1.首先导入包

struts2的五个基础包:

commons-logging-1.1.jar;

freemarker-2.3.8.jar;

ognl-2.6.9.jar;

struts-core-2.0.6.jar;

xwork-2.0.0.jar.

spring的核心包:spring.jar

二者集成开发所需的包:struts-spring-plugin-2.0.6.jar

2.修改web.xml配置文件

配置spring加载上下文时的监听器

<listener>

<listener-class>

org.springframework.web.context.ContextLoaderListener

</listener-class>

</listener>

3.配置applicationContext.xml

4.OVER