逝夕诚

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::

原文地址:http://blog.163.com/sparkle_tiangz/blog/static/117590203201011042727965/

1.在页面中对你的URL进行编码

      使用------encodeURI(你要使用的中文参数值)如:...?username"+encodeURI(“小甜甜")

2.在后台通过解码来接收该中文参数

     使用----String name = new String(request.getParameter("username ").getBytes("iso8859-1"),"utf-8")

3.最好不要在URL中传递中文参数

posted on 2016-03-18 10:40  逝夕诚  阅读(144)  评论(0)    收藏  举报