请求:对于get和post都有效果
request.setCharacterEncoding("UTF-8");
相应:
设置服务器输出的编码为UTF-8
response.setCharacterEncoding("UTF-8");
或者:
response.setContentType("text/html; charset=utf-8");
本文共 174 字,大约阅读时间需要 1 分钟。
request.setCharacterEncoding("UTF-8");
response.setCharacterEncoding("UTF-8");
或者:
response.setContentType("text/html; charset=utf-8");
转载地址:http://mkzum.baihongyu.com/