Struts2.3.7 + Tiles 2.0.6 所需要jar包 及 中文出现乱码


配置环境:Struts2.3.7 + Tiles 2.0.6 + spring3.05 + hibernate3.6.8
web.xml中的配置
<!--  tiles2 listener -->
   < context-param >
     < param-name >org.apache.tiles.CONTAINER_FACTORY </ param-name >
     < param-value >org.apache.struts2.tiles.StrutsTilesContainerFactory </ param-value >
   </ context-param >
   < context-param >
     < param-name >org.apache.tiles.impl.BasicTilesContainer.DEFINITIONS_CONFIG </ param-name >
     < param-value >/WEB-INF/tiles.xml </ param-value >
   </ context-param >
   < listener >
     < listener-class >org.apache.struts2.tiles.StrutsTilesListener </ listener-class >
   </ listener >
  <!--  tiles end -->


出现中文乱码在 web.xml配置
<!-- 配置spring过滤器处理乱码    -->
   < filter >
     < filter-name >CharacterEncodingFilter </ filter-name >
     < filter-class >org.springframework.web.filter.CharacterEncodingFilter </ filter-class >
    <!-- 设置字符编码 默认值设置了请求的字符编码 -->
     < init-param >
       < param-name >encoding </ param-name >
       < param-value >utf-8 </ 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 >

Tiles 2 所需jar包
commons-beanutils-1.8.0.jar
commons-digester-2.0.jar
struts2-tiles-plugin-2.3.7.jar
tiles-api-2.0.6.jar
tiles-core-2.0.6.jar
tiles-jsp-2.0.6.jar







你可能感兴趣的:(struts2,中文乱码,tiles,jar包)