当前位置: 代码迷 >> Web前端 >> 在web.xml中施用监听器初始化spring容器
  详细解决方案

在web.xml中施用监听器初始化spring容器

热度:145   发布时间:2012-10-23 12:12:22.0
在web.xml中使用监听器初始化spring容器
<!-- 采用Listener完成Spring容器的初始化 -->
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>
/WEB-INF/applicationContext.xml
</param-value>
</context-param>
  相关解决方案