This week's book giveaways are in the Angular and TypeScript and Web Services forums.
We're giving away four copies each of Programming with Types and The Design of Web APIs and have the authors on-line!
See this thread and this one for details.
Win a copy of Programming with Types this week in the Angular and TypeScript forum
or The Design of Web APIs in the Web Services forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Knute Snortum
  • Henry Wong
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Frits Walraven
  • Joe Ess
  • salvin francis

JSF/MyFaces and Sitemesh

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all, im having problem with JSF code in my sitemesh decorator files. i get this error if im putting in some JSF code, like <f:view> ... </f:view> in my default decorator file. It works fine in my other JSP files (Those that displays through the <decorator:body/> tag)

------------------------------------------------------------
javax.faces.FacesException: Faces context not found. getResponseWriter will fail. Check if the FacesServlet has been initialized at all in your web.xml configuration fileand if you are accessing your jsf-pages through the correct mapping. E.g.: if your FacesServlet is mapped to *.jsf (with the -element), you need to access your pages as 'sample.jsf'. If you tried to access 'sample.jsp', you'd get this error-message.
at javax.faces.webapp.UIComponentTag.setupResponseWriter(UIComponentTag.java:926)
at javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:313)
at org.apache.myfaces.taglib.core.ViewTag.doStartTag(ViewTag.java:73)
at org.apache.jsp.decorators.default_jsp._jspx_meth_f_005fview_005f0(default_jsp.java:341)
at org.apache.jsp.decorators.default_jsp._jspService(default_jsp.java:167)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
at javax.servlet.http.HttpServlet.service(Servlet.java:803)

----------------------------------------------------------------------------

Anyone got this problem, solved it also maybe :-)

My env is:

Tomcat 5.5 / Servlet 2.4.
myfaces, 1.1.5
sitemesh, 2.2.1
 
Would you turn that thing down? I'm controlling a mind here! Look ... look at the tiny ad ...
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!