| Author |
How to declare multiple message bundles in Faces-config.xml
|
Priti Shah
Ranch Hand
Joined: May 10, 2005
Posts: 43
|
|
Hi I have different properties file which I want to use as message bundle. Message.properties Help.properties When I specify this in faces-config.xml <application> <message-bundle>/Message</message-bundle> <message-bundle>/Help</message-bundle> </application> and now when I try to use that in my jsp page like this <f:loadBundle basename="/Message" var="message"/> <f:loadBundle basename="/Help" var="help"/> and access any messagestring from those files I can not excess either of them. But when I use only one of them it works fine. Am I doing something wrong or I can not do this thing at all?? Thanks in advance.
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15229
|
|
Works fine for me. Although my syntax is a bit different:
|
 |
Priti Shah
Ranch Hand
Joined: May 10, 2005
Posts: 43
|
|
Hi greg, Thanks for the quick reply. It is working for me but i found that problem is in my custom component. In my jsp I am using these bundles like this <f:loadBundle basename="/Message" var="message"/> <f:loadBundle basename="/Help" var="help"/> Now in my custom component I am getting ResourceBundle from the current context and it is returning me 'help' but my messagekey is in 'message' bundle. Any suggestions how can I do this. Thanks
|
 |
 |
|
|
subject: How to declare multiple message bundles in Faces-config.xml
|
|
|