java - JSF 1.2: Navigation rules in a different config file -
i using jsf 1.2 application. trying create separate config file (named: navigation-config.xml) navigation rules throughout application. below steps followed same:
made entry in web.xml
file , placed same directory faces-config.xml
present:
<context-param> <param-name>javax.faces.application.config_files</param-name> <param-value>/web-inf/faces-config.xml,/web-inf/navigation-config.xml</param-value> </context-param>
below content of navigation-config.xml
:
<?xml version='1.0' encoding='utf-8'?> <!doctype faces-config public "-//sun microsystems, inc.//dtd javaserver faces config 1.1//en" "http://java.sun.com/dtd/web-facesconfig_1_1.dtd"> <faces-config> <navigation-rule> <description>welcome screen navigation</description> <from-view-id>/login.jspx</from-view-id> <navigation-case> <from-outcome>success</from-outcome> <to-view-id>/welcome.jspx</to-view-id> </navigation-case> </navigation-rule> </faces-config>
when success
, navigation not happening. if remove <navigation-rule>
navigation-config.xml
, add faces-config.xml
file navigation working means there problems navigation-config.xml
file navigation having problems.
please let me know how resolve this, need separate file indicating navigation rules.
try following...
make changes in web.xml file
> <context-param> > <param-name>javax.faces.application.config_files</param-name> > <param-value>/web-inf/faces-config.xml</param-value> > <param-value>/web-inf/navigation-config.xml</param-value> </context-param>
Comments
Post a Comment