Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/jsf/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Jsf 在目录外导航到primefaces中的其他目录_Jsf_Path_Facelets_Templating - Fatal编程技术网

Jsf 在目录外导航到primefaces中的其他目录

Jsf 在目录外导航到primefaces中的其他目录,jsf,path,facelets,templating,Jsf,Path,Facelets,Templating,我正在使用素面模板,但我似乎无法正确使用。我一直收到一个500错误。我基本上是在尝试从createorder.xhtml导航到WEB-INF/templates/fullpagetemplate.xhtml 我现在在createorder.xhtml中的路径是: template="/WEB-INF/templates/fullpagetemplate.jsf" 我一直得到一个例外: Servlet.service() for servlet Faces Servlet threw excep

我正在使用素面模板,但我似乎无法正确使用。我一直收到一个
500错误
。我基本上是在尝试从
createorder.xhtml
导航到
WEB-INF/templates/fullpagetemplate.xhtml

我现在在createorder.xhtml中的路径是:

template="/WEB-INF/templates/fullpagetemplate.jsf"
我一直得到一个例外:

Servlet.service() for servlet Faces Servlet threw exception: javax.faces.view.facelets.TagAttributeException: /order/createorder.xhtml @7,53 <ui:composition template="/WEB-INF/templates/fullpagetemplate.jsf"> Invalid path : /WEB-INF/templates/fullpagetemplate.jsf
Servlet Faces的
Servlet.service()Servlet引发异常:javax.Faces.view.facelets.TagAttributeException:/order/createorder.xhtml@7,53无效路径:/WEB-INF/templates/fullpagetemplate.jsf

文件结构的屏幕截图:


在导航到
WEB-INF
目录之前,您需要先上一个目录,在文件路径前面加上
如下:

template="../WEB-INF/templates/fullpagetemplate.jsf"

在导航到
WEB-INF
目录之前,您需要先上一个目录,方法是在文件路径前面加上
如下所示:

template="../WEB-INF/templates/fullpagetemplate.jsf"

为什么你会接受一个不起作用的答案?为什么你会接受一个不起作用的答案?