hibernate与struts、spring三大框架整合中web-xml的使用
发布时间:2021-06-07
发布时间:2021-06-07
hibernate与struts、spring三大框架整合中web-xml的使用介绍
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.4"
xmlns="/xml/ns/j2ee"
xmlns:xsi="/2001/XMLSchema-instance"
xsi:schemaLocation="/xml/ns/j2ee
/xml/ns/j2ee/web-app_2_4.xsd">
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<!--配置Struts-->
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<!-- 日期转换-->
<servlet>
<servlet-name>initServlet</servlet-name>
<servlet-class>com.bjsxt.oa.web.InitServlet</servlet-class>
<load-on-startup>3</load-on-startup>
</servlet>
<!-- Standard Action Servlet Mapping -->
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
<!-- 指明Spring的application文件的位置 -->
<context-param>
上一篇:政府采购公开招标文件