1.汉字参数直接跟在请求连接的后面,这样需要使用encodeURIComponent(fileName)或者encodeURI(fileName)转码两次
后台使用URLDecoder.decode(fileName, "UTF-8");
2.如果参数发在data属性后,可以只使用encodeURIComponent(fileName)或者encodeURI(fileName)转码一次.后台使用URLDecoder.decode(fileName, "UTF-8");.
1.汉字参数直接跟在请求连接的后面,这样需要使用encodeURIComponent(fileName)或者encodeURI(fileName)转码两次
后台使用URLDecoder.decode(fileName, "UTF-8");
2.如果参数发在data属性后,可以只使用encodeURIComponent(fileName)或者encodeURI(fileName)转码一次.后台使用URLDecoder.decode(fileName, "UTF-8");.
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。