JSF navigation初级应用

来源:互联网 发布:linux exec作用 编辑:程序博客网 时间:2024/05/21 15:41

<navigation-rule>

    <from-view-id>/pages/index.jsp</from-view-id>

    <navigation-case>

        <from-outcome>success</from-outcome>

        <to-view-id>/pages/welcome.jsp</to-view-id>

        <redirect/>

    </navigation-case>

    <navigation-case>

        <from-outcome>failure</from-outcome>

        <to-view-id>/pages/register.jsp</to-view-id>

        <redirect/>

    </navigation-case>

</navigation-rule>

 

navigation-rule ---- 一个input对应一个

from-view-id ---- input页面

 

navigation-case:

   -- from-outcome   :   对应的字符串,就相当于key,当得到success这个值的时候,就到to-view-id的结果页面

   -- to-view-id    :    结果页面

   -- redirect       :     设定为重定向

 

原创粉丝点击