web.xml中配置解决中文乱码的过滤器

  • Post author:
  • Post category:其他



<!–配置解决中文乱码的过滤器–>


<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>


</filter>


<filter-mapping>


<filter-name>characterEncodingFilter</filter-name>


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


</filter-mapping>



版权声明:本文为weixin_65449886原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。