In every page of my webapplication I'm using facelets layout page which includes a stylesheet. In order to include the stylesheet I've tried the following options:
Determining the absolute path using a
JSF expression:
<link rel="stylesheet" type="text/css" href="#{facesContext.externalContext.request.contextPath}/theme/stylesheet.css" />
And by using the tomahawk stylesheet tag:
<t:stylesheet path="/theme/stylesheet.css" />
I'm using an index.jsp page which forwards to the first page of my webapplication using:
<
jsp:forward page="shop/selectbicycle.jsf" />
However, I encounter the following problem:
When I access the index.jsp page it forwards to the selectbicycle.xhtml page and I see my page with the right layout. In other words, the CSS gets applied.
However, after the next requests to other facelets pages (*.jsf gets mapped to *.xhtml), the CSS is not applied to the pages.
Can anyone help me with this? Thanks a lot.
By the way, my layout page looks as follow:
[ April 19, 2007: Message edited by: Paul Speijers ]