I hope tomcat parse the jsp file with the GBK encoding,so I set the javaEncoding paramater's value to "GBK".

The simple JSP file is:

<html>
<body>
output: Something String
</body>
</html>

My operation system is chinese GBK charset. When I replace "Something String" to chinese text,I found the parsed java source file by tomcat have some "???" char.

I add charset setting to the jsp file:

<%@ page language="java" contentType="text/html;charset=GBK" %>
<html>
<body>
output: Something String
</body>
</html>

And the parsed java source file is correct!It can display the right chinese text.

I thought the javaEncoding parameter value is used when parse a jsp file to java source file,and jsp file's charset setting is used when response to the client.But it seems not work well.

_________________________________________________________________
与联机的朋友进行交流,请使用 MSN Messenger: http://messenger.msn.com/cn



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to