1

有什么办法可以实现从文件“file1.xhtml”导航到位于父文件夹中的另一个文件“file2.xhtml”,根本不使用“faces-config.xml”导航。

ProjectName
+---+
    WebContent
    +---+
    |   subfolder
    |   +---+
    |       file1.xhtml
    +---+
        file2.xhtml

从 file2.xhtml 导航到 file1.xml:

<h:link value="Go to file1" outcome="subfolder/file2" />

从 file1.xhtml 导航到 file2.xml:

<h:link value="Go to file2" outcome="?" />
4

1 回答 1

2

以下应该工作

<h:link value="Go to file1" outcome="/file1" />
于 2013-08-01T07:52:18.920 回答