Announcement Announcement Module
Collapse
No announcement yet.
JSF + Facelets + Spring (swf) Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • JSF + Facelets + Spring (swf)

    Does any one woking with all JSF + Facelets + Spring (swf).
    I have hard time configuring both JSF & Facelets together.
    I could make JSF(.jsf) or Facelets(.xhtml) working individually, But when try to combine both, it just seems doest like it.

    Any ideas...

  • #2
    I know of some people using this combination.
    Since your problem is Facelets related you'll probably have more success getting an answer on the JSF/Facelets forums.

    Erwin

    Comment


    • #3
      I have used this combination and gotten them to work together.
      Here are my web.xml and faces.config files...

      Code:
      <?xml version="1.0" encoding="UTF-8"?>
      <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
          <context-param>
              <param-name>com.sun.faces.validateXml</param-name>
              <param-value>true</param-value>
          </context-param>
          <context-param>
              <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
              <param-value>.xhtml</param-value>
          </context-param>
          <context-param>
              <param-name>facelets.DEVELOPMENT</param-name>
              <param-value>true</param-value>
          </context-param>
          <context-param>
              <param-name>facelets.SKIP_COMMENTS</param-name>
              <param-value>true</param-value>
          </context-param>
          <context-param>
            <param-name>contextConfigLocation</param-name>
            <param-value>/WEB-INF/webflow-config.xml</param-value>
          </context-param>
          <context-param>
              <param-name>debugMode</param-name>
              <param-value>true</param-value>
          </context-param>
          <context-param>
              <param-name>facelets.LIBRARIES</param-name>
             <param-value>/WEB-INF/facelets/tags/cvg.taglib.xml;/WEB-INF/facelets/tags/woodstock.taglib.xml;/WEB-INF/facelets/tags/jsf-ext-dynafaces.taglib.xml</param-value>
          </context-param>
      
          <listener>
            <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
          </listener>
          <servlet>
              <servlet-name>Faces Servlet</servlet-name>
              <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
              <load-on-startup>1</load-on-startup>
          </servlet>
      
            
          <servlet-mapping>
              <servlet-name>Faces Servlet</servlet-name>
              <url-pattern>*.jsf</url-pattern>
          </servlet-mapping>
      
          </web-app>
      Code:
      <?xml version="1.0" encoding="UTF-8"?>
      <faces-config version="1.2" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd">
        <application>
          <message-bundle>com.convergys.ValidationMessages</message-bundle>
          <navigation-handler>
            org.springframework.webflow.executor.jsf.FlowNavigationHandler
          </navigation-handler>
          <variable-resolver>
            org.springframework.webflow.executor.jsf.DelegatingFlowVariableResolver
          </variable-resolver>
      
          <view-handler>
            com.sun.facelets.FaceletViewHandler
          </view-handler>
        </application>
        <lifecycle>
          <phase-listener>org.springframework.webflow.executor.jsf.FlowPhaseListener</phase-listener> 
        </lifecycle>
      
      </faces-config>
      Hope it helps

      Comment


      • #4
        I nice facelets sellitem-jsf example would really help newbies get off to a flyer...just a thought. :-p

        Comment

        Working...
        X