We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
我按照 四步完成Spring国际化动态配置 上面配好了resolver
并在controller里处理:
@Get public String index(Invocation inv, @Param("language") String language) { if (language != null) { Locale locale = org.springframework.util.StringUtils.parseLocaleString(language); logger.debug("language: {}, locale: {}", language, locale); resolver.setLocale(inv.getRequest(), inv.getResponse(), locale); } return "index"; }
在jsp里打印:
${pageContext.request.locale}, <spring:message code="web.title"/>
结果 /?language=zh_CN 访问,logger里能打出来是:zh_CN,cookie里也能看到是zh_CN 但是jsp里,仍然是en_US 求教。。。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
我按照 四步完成Spring国际化动态配置 上面配好了resolver
并在controller里处理:
在jsp里打印:
结果 /?language=zh_CN 访问,logger里能打出来是:zh_CN,cookie里也能看到是zh_CN
但是jsp里,仍然是en_US
求教。。。
The text was updated successfully, but these errors were encountered: