您的位置:首页 > 移动开发

读取资源文件的方法 ApplicationResources.properties

2006-04-13 14:10 711 查看
读取资源文件的方法

方法一:
jsp中:<bean:message key="lable.username"/>
方法二:
MessageResources.getMessageResources("com.yourcompany.struts.ApplicationResources");
MESSAGE.getMessage(Locale.CHINESE,"error.username");

注:
getMessageResources()参数为在struts-config.xml中定义的<message-resources parameter="profile.resources.ApplicationResources"/>中的parameter信息。

谢谢大家^o^
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: