-
result配置参数时, 需要添加
charSet参数<result type="codeResult"> <param name="charSet">UTF-8</param> <param name="str1">"你好"</param> <param name="str2">"我是依赖注入"</param> </result> -
doExcute()方法处理请求时, 需要在response中执行MIME-Type// 通过获取Action的上下文, 获取response对象 HttpServletResponse response = ServletActionContext.getResponse(); response.setContentType("text/html; charset=utf-8"); -
编辑前: "?????""????????"
-
配置后: "你好""我是依赖注入"












网友评论