[英]Pretty Faces Mapping problem
我對Pretty URL使用PrettyFaces,但是對PrettyFaces遇到了第一個問題:pretty-config.xml中的映射
<url-mapping id="home">
<pattern value="/" />
<view-id>/faces/index.jsf</view-id>
</url-mapping>
我在服務器URL http:// localhost / myproject上部署時有一個文件index.xhtml,找不到index.jsf,這是怎么回事?
在prettyfaces的web.xml中映射
<!-- PrettyFaces-->
<filter>
<filter-name>Pretty Filter</filter-name>
<filter-class>com.ocpsoft.pretty.PrettyFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>Pretty Filter</filter-name>
<url-pattern>/*</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>ERROR</dispatcher>
</filter-mapping>
<!-- End PrettyFaces-->
GlassFish問題消息
HTTP Status 404 - /index.jsf not found
type Status report
message/index.jsf not found
descriptionThe requested resource (/index.jsf not found) is not available.
index.jsf
文件不存在。 將其放在項目的根目錄中(http://localhost/myproject/index.jsf)。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.