1.较好的处理办法,对js的url中的中文参数值使用两次encodeURI(),即

encodeURI(encodeURI("url的中文参数值")),

java代码中使用URLDecoder.decode(request.getParameter("variables"),"UTF-8")方法获得参数值;

这个方法则不依赖tomcat的字符集设置

相关文章:

  • 2022-12-23
  • 2021-05-18
  • 2022-12-23
  • 2021-10-21
  • 2022-12-23
  • 2021-09-22
  • 2022-02-20
  • 2022-12-23
猜你喜欢
  • 2021-12-06
  • 2021-08-20
  • 2022-12-23
  • 2021-08-10
相关资源
相似解决方案