How can I access a value from the "messages" file in a controller?
For example, in my "messages" file:
app.name = Play Framework App
How can I get 开发者_JAVA百科the value of app.name
in a Controller?
You can access it with following code
Messages.get("app.name")
Also see http://www.playframework.org/documentation/1.2.3/i18n#retrieve
精彩评论