Spring

web.xml

닉넥임 2013. 9. 25. 10:37
반응형

<?xml version="1.0" encoding="UTF-8"?>

<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">


<!-- The definition of the Root Spring Container shared by all Servlets and Filters -->

<context-param>

<param-name>contextConfigLocation</param-name>

<param-value>

/WEB-INF/spring/root-context.xml

/WEB-INF/spring/spring-security-context.xml

</param-value>

</context-param>


<!--  Spring Security Filter Chain -->

    <filter>

        <filter-name>springSecurityFilterChain</filter-name>

        <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>

    </filter>

 

    <filter-mapping>

        <filter-name>springSecurityFilterChain</filter-name>

        <url-pattern>/*</url-pattern>

    </filter-mapping>

 

<listener>

<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>

</listener>


<!-- Processes application requests -->

<servlet>

<servlet-name>appServlet</servlet-name>

<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>

<init-param>

<param-name>contextConfigLocation</param-name>

<param-value>/WEB-INF/spring/appServlet/servlet-context.xml</param-value>

</init-param>

<load-on-startup>1</load-on-startup>

</servlet>

<servlet-mapping>

<servlet-name>appServlet</servlet-name>

<url-pattern>/</url-pattern>

</servlet-mapping>

<!-- Korean Filter -->

<filter>

   <filter-name>CharacterEncodingFilter</filter-name>

   <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>

   <init-param>

     <param-name>encoding</param-name>

     <param-value>EUC-KR</param-value>

   </init-param>

   <init-param>

     <param-name>forceEncoding</param-name>

     <param-value>true</param-value>

   </init-param>

 </filter>

  

 <filter-mapping>

   <filter-name>CharacterEncodingFilter</filter-name>

   <url-pattern>/*</url-pattern>

 </filter-mapping>


</web-app>



반응형

'Spring' 카테고리의 다른 글

Controller @RequestParam  (1) 2013.10.07
String Mybatis 연동 및 간단예제(select, insert)  (8) 2013.10.01
Maven 정보(pom.xml) 모음  (0) 2013.09.05
ibatis, mybatis 가이드 이동국 pdf  (0) 2013.09.04
STS(Spring Tool Suite)설치하기  (0) 2013.08.20