iframe中传接中文参数出现乱码

iframe中传递中文参数出现乱码

两个方法:
1.字符集用UTF-8
2。用encodeURI手动进行字符集转换

Java code

String str = java.net.URLDecoder.decode(str, "UTF-8");