我有一些问题处理我的web应用程序的国际化。 是否有可能通过Spring在MessageSource中找到消息,如果在其他消息中找不到消息?如何在2个消息包之间切换?
这是我的Spring配置
<bean id="messageSource"
class="org.springframework.context.support.ResourceBundleMessageSource">
<property name="basename" value="xxMessage" />
</bean>
<bean id="localeResolver"
class="org.springframework.web.servlet.i18n.SessionLocaleResolver">
<property name="defaultLocale" value="en" />
</bean>
举例:如果 关键是“login.user”和区域设置为“EN”的应用会显示在我的xx_en.properties的值,如果存在,但我如果该键不存在,则要在其他文件(xx_es.properties)中进行搜索。 这可能吗?
P.S:对不起,我的英语:D
在此先感谢!