Note that there are some explanatory texts on larger screens.

plurals
  1. PONavigation with Facelets template not working
    primarykey
    data
    text
    <p>I'm having some trouble with navigation when using Facelets.</p> <p>I have my master template in <code>/WEB-INF</code>:</p> <pre><code>&lt;h:body&gt; &lt;div id="container"&gt; &lt;div id="header"&gt; &lt;ui:insert name="header"&gt;Header&lt;/ui:insert&gt; &lt;/div&gt; &lt;div id="navigation"&gt; &lt;a href="ram.xhtml"&gt;RAM&lt;/a&gt; &lt;a href="mobo.xhtml"&gt;Motherboard&lt;/a&gt; &lt;a href="video.xhtml"&gt;Video Card&lt;/a&gt; &lt;/div&gt; &lt;div id="content"&gt; &lt;ui:insert name ="content"&gt;&lt;/ui:insert&gt; &lt;/div&gt; &lt;/div&gt; &lt;/h:body&gt; </code></pre> <p>and then 2 template clients that look exactly the same, <code>index.xhtml</code> and <code>ram.xhtml</code>:</p> <pre><code>&lt;?xml version='1.0' encoding='UTF-8' ?&gt; &lt;!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; &lt;ui:composition xmlns:ui="http://java.sun.com/jsf/facelets" template="./WEB-INF/layoutTemplate.xhtml"&gt; &lt;ui:define name="header"&gt; some text &lt;/ui:define&gt; &lt;ui:define name="content"&gt; some content &lt;/ui:define&gt; &lt;/ui:composition&gt; </code></pre> <p>If either of these pages are set as the welcome page in the <code>web.xml</code>, they are rendered correctly, with CSS and everything. But if I try to navigate from one page to the other using the link I get </p> <blockquote> <p>This XML file does not appear to have any style information associated with it. The document tree is shown below.</p> </blockquote> <p>Any hints would be greatly appreciated.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload