Google App Engine does not parse JSF 2.0 tags

后端 未结 3 1557
悲&欢浪女
悲&欢浪女 2021-01-21 15:59

I have a problem with running JSF 2.0 on AppEngine. I have following index.xhtml and if I deploy it and open the page, there is nothing but the Title

3条回答
  •  攒了一身酷
    2021-01-21 16:30

    This can happen if the request URL as you've in the browser address bar does not match the URL pattern of the FacesServlet as definied in web.xml. It's the one responsible for parsing the Facelet file, creating the FacesContext and doing all the JSF works.

    You have mapped the FacesServlet on /faces/*, so that means that you've to include /faces/ after the context path in the request URL to get it to run. I.e.

    http://example.com/contextpath/faces/index.xhtml

    Alternatively, you can also change the URL pattern to

    *.xhtml
    

    so that all XHTML (Facelet) files will be parsed by FacesServlet anyway.

提交回复
热议问题