Chinese garbled generally in the code to set the encoding method,
getResponse().setCharacterEncoding(Constant.CODE_UTF_8);getRequest().setCharacterEncoding(Constant.CODE_UTF_8);
But this is only valid for post, and for get it needs to be configured in the Web container, Tomcat configuration reference: http://blog.csdn.net/calmreason/article/details/44591029
JBoss is special, the previous version of 7 in a configuration file, the specific file name does not remember, but 7.0 does not support, reference: http://jbosscn.iteye.com/blog/1180591 This post of the six floor review
So we need to use JBoss7.1, the specific configuration is to add in the Jboss-as-7.1.0.final\standalone\configuration\standalone.xml
</extensions ; **< Span class= "Hljs-tag" ><system-properties ; <property name = "Org.apache.catalina.connector.URI_ENCODING" value = "UTF-8" /> < Property name = " Org.apache.catalina.connector.USE_BODY_ENCODING_FOR_QUERY_STRING " value =/> </ system-properties ; * * < management ;
Reference: http://www.iflym.com/index.php/code/201212270001.html
JBOSS7 encoding of Get mode in JBOSS7 Chinese characters