Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within JSF
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
JSF
multiple faces config files
Richard Green
Ranch Hand
Posts: 536
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
can some one explain me how to split my faces config file into two seperate files:
currently i have:
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN" "http://java.sun.com/dtd/web-facesconfig_1_0.dtd"> <faces-config> <application> <message-bundle>bundles.xxx.core</message-bundle> <locale-config> <default-locale>en</default-locale> </locale-config> </application> <managed-bean> <managed-bean-name>firstBean</managed-bean-name> <managed-bean-class> au.xxx.FirstBean </managed-bean-class> <managed-bean-scope>session</managed-bean-scope> </managed-bean> <managed-bean> <managed-bean-name>secondBean</managed-bean-name> <managed-bean-class> au.xxx.SecondBean </managed-bean-class> <managed-bean-scope>session</managed-bean-scope> </managed-bean> </faces-config>
am i correct in splitting them as follows:
1st config file:
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN" "http://java.sun.com/dtd/web-facesconfig_1_0.dtd"> <faces-config> <application> <message-bundle>bundles.xxx.core</message-bundle> <locale-config> <default-locale>en</default-locale> </locale-config> </application> <managed-bean> <managed-bean-name>firstBean</managed-bean-name> <managed-bean-class> au.xxx.FirstBean </managed-bean-class> <managed-bean-scope>session</managed-bean-scope> </managed-bean> </faces-config>
2nd config file
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN" "http://java.sun.com/dtd/web-facesconfig_1_0.dtd"> <faces-config> <application> <message-bundle>bundles.xxx.core</message-bundle> <locale-config> <default-locale>en</default-locale> </locale-config> </application> <managed-bean> <managed-bean-name>second</managed-bean-name> <managed-bean-class> au.xxx.SecondBean </managed-bean-class> <managed-bean-scope>session</managed-bean-scope> </managed-bean> </faces-config>
MCSD, SCJP, SCWCD, SCBCD, SCJD (in progress - URLybird 1.2.1)
Sergey Smirnov
Ranch Hand
Posts: 167
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
It is correct, but there is not reason to repeat application section in the second file. The definitions of faces config files are merged together.
--
Sergey :
https://ajax4jsf.dev.java.net/
After some pecan pie, you might want to cleanse your palatte with this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
Problem in setting bean scope to request
problem with SelectOneListbox
Which Package to Import to Use FacesContext's getRequestMap()?
message-bundle not working
In which order check if some attribute doesn't work
More...