Skip to Main Content

JSF page navigation under WEB-INF

lfdJul 16 2013

If page navigation starts on index.xhtml, and then forwards to page2.xhtml, how can I then forward from page2.xhtml to page3.xhtml?

WebContent

  META-INF

  WEB-INF

    lib

    pages

      page2.xhtml

      page3.xhtml

    faces-config.xml

    web.xml

  index.xhtml

Controller.java

class Controller {

public String gotopagetwo(){

return "/WEB-INF/pages/page2";

public String gotopagethree(){

return "/WEB-INF/pages/page3";

}



index.xhtml

h:commandButton id="submit" value="Submit" action="#{con.gotopagetwo}"></h:commandButton>

page2.xhtml

h:commandButton id="submit" value="Submit" action="#{con.gotopagethree}"></h:commandButton>

Comments
Post Details
Added on Jul 16 2013
0 comments
1,056 views