struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lukasz Lenart (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (WW-4829) Set a global resource bundle in class
Date Sun, 30 Jul 2017 09:54:00 GMT

    [ https://issues.apache.org/jira/browse/WW-4829?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16106409#comment-16106409
] 

Lukasz Lenart commented on WW-4829:
-----------------------------------

The best option is to use {{struts.custom.i18n.resources}} but if you need to do it programmatically
you will have to options:
- inject the {{LocalizedTextProvider}} into an action and add the resource bundles
- implement your own version of the {{LocalizedTextProvider}} and register as it was shown
here in [Using only global bundles|http://struts.apache.org/docs/localization.html#Localization-Usingonlyglobalbundles]

> Set a global resource bundle in class 
> --------------------------------------
>
>                 Key: WW-4829
>                 URL: https://issues.apache.org/jira/browse/WW-4829
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.5.12
>            Reporter: Alireza Fattahi
>             Fix For: 2.5.13
>
>
> In struts 2.5.12 the *LocalizedTextUtil* is removed.
> We used to `*LocalizedTextUtil.addDefaultResourceBundle*` in our classes to add resource
bundles. This was mentioned in https://struts.apache.org/docs/how-do-i-set-a-global-resource-bundle.html
> Can you please let me know how this can be done with this change ?!



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message