jsp get 提交 如提交 中文亂碼

前臺jsp  提交需要兩次encodeURI處理中文參數

$.pdialog.open("goUserEmployeeDetail.jhtml?userinfo.name="+encodeURI(encodeURI('中國'))+"&userinfo.mobile="+umobile+"&userinfo.wxId="+ uwxid, "addType",
     "添加角色", {
      "height" : "400",
      "width" : "500",
      "max" : false,
      "mask" : true,
      "minable" : false,
      "maxable" : false
    });

 

 

後臺需要

String loginName = java.net.URLDecoder.decode(‘中國’,"UTF-8");

處理

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章