日期:2014-05-17 浏览次数:20799 次
<?xml version="1.0" encoding="UTF-8"?> <web-app> <servlet-mapping> <servlet-name>default</servlet-name> <url-pattern>*.jpg</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>default</servlet-name> <url-pattern>*.png</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>default</servlet-name> <url-pattern>*.gif</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>default</servlet-name> <url-pattern>*.js</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>default</servlet-name> <url-pattern>*.css</url-pattern> </servlet-mapping> <servlet> <servlet-name>spring</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>spring</servlet-name> <url-pattern>/</url-pattern> </servlet-mapping> <welcome-file-list> <welcome-file>login.jsp</welcome-file> </welcome-file-list> </web-app>
<?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:p="http://www.springframework.org/schema/p" xmlns:context="http://www.springframework.org/schema/context" xmlns:aop="http://www.springframework.org/schema/aop" xmlns:tx="http://www.springframework.org/schema/tx" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.0.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.0.xsd http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd"> <!-- 自动扫描的包名 --> <context:component-scan base-package="cn.spring.app.controller" /> <!-- 默认的注解映射的支持 --> <mvc:annotation-driven /> <!-- 视图解释类 --> <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"> <property name="prefix" value="/WEB-INF/jsp/" /> <property name="suffix" value=".jsp" /> <property name="viewClass" value="org.springframework.web.servlet.view.JstlView" /> </bean> <!-- 拦截器 --> <!-- 对静态资源文件的访问 --> <mvc:default-servlet-handler /> </beans>
![]()
推荐阅读更多>
- 请教jsp小偷程序如何写?200分
- 用bean写一个js文件,怎么将js文件的格式保存为utf-8格式
- 有关问题:没有显示出异常,但是输不出自己想的要结果
- 已经有了unicode编码,为什么还要UTF8,UTF16呢,该怎么解决
- 请教怎么在java中实现对oracle数据库的操作
- jar文件执行异常
- xmGraph里xml的格式如何写
- 刚学JSP 问点有关问题
- 运用数字签名,可以访问文件,但是还是没有权限使用录音
- java程序怎么接收一个视频文件,并且要在网页上变接收边播放
- J2EE的十三种技术(轨范)
- JSP页面checkbox值传数据库有关问题
- 关于java的一个语法有关问题
- Java TCP接收大文件OutofMemoryError,该如何解决
- 怎样 在代码中加载一个Jar包
- java 怎么存储数据表
- 【散分】当准父亲了
- 关于word的预览功能如何实现 求教
- 有些受挫。散点分
- WML调用Servlet中文乱码有关问题