Extjs提交表单时出现中文乱码的解决方法
2014-03-17 15:57
537 查看
1、在web.xml中加入有关字符的配置
<filter>
<filter-name>encodingFilter</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>
2、在jsp页面配置中文设置
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<meta content="text/html;charset='utf-8'" http-equiv="Content-Type">
3、在js引入时设定字符格式
<script type="text/javascript" charset="utf-8" src="common/common.js"></script>
4、在struts.xml中设置字符配置
<constant name="struts.i18n.encoding" value="utf-8"/>
<filter>
<filter-name>encodingFilter</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>
2、在jsp页面配置中文设置
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<meta content="text/html;charset='utf-8'" http-equiv="Content-Type">
3、在js引入时设定字符格式
<script type="text/javascript" charset="utf-8" src="common/common.js"></script>
4、在struts.xml中设置字符配置
<constant name="struts.i18n.encoding" value="utf-8"/>
相关文章推荐
- JSP表单提交出现中文乱码的解决方法
- tomcat里面表单以get方式提交出现中文乱码解决方法
- JSP页面表单提交时出现中文乱码的解决方法
- JSP 表单输入,UTF编码,get方式提交数据出现中文乱码解决方法
- JSP页面表单提交时出现中文乱码的解决方法
- Spring MVC中表单提交中文出现乱码解决方法
- Spring3.0_MVC中解决提交表单时产生的中文乱码的方法
- 解决中文乱码( jsp表单提交中文时出现乱码)
- ajax post 提交中文java后台获取参数出现乱码解决方法
- 解决中文乱码( jsp表单提交中文时出现乱码)
- ajax post 提交中文java后台获取参数出现乱码解决方法
- 使用get方法提交form表单时出现乱码解决方法
- java表单提交中文乱码的解决方法
- ajax表单提交使用serialize()方法解决中文乱码
- Extjs4 store load 有中文字符提交后台乱码解决方法
- JSP中乱码问题解决(一、JSP页面显示乱码,二、表单提交中文时出现乱码,三、数据库连接出现乱码,四、数据库的显示乱码 )
- [j2ee][servlet]使用get方法提交form表单时出现乱码解决方法
- Ajax提交表单中文乱码的一种解决方法
- js提交表单中包含中文参数值,request请求参数正常,服务器端接收出现乱码解决思路
- JSP表单提交中文乱码解决方法(使用过滤器)(GET方法无效)