Announcement Announcement Module
Collapse
No announcement yet.
JSF Components are not converted into html Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • JSF Components are not converted into html

    I am facing a problem with jsf, the jsf integrated with webflow,i am able to navigate to the page,but the jsf components are not rendered as html in the web browser,rather they are written as it is.


    applicationContext.xml


    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:context="http://www.springframework.org/schema/context"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
    xmlns="http://www.springframework.org/schema/p" xmlns:faces="http://www.springframework.org/schema/faces"
    xmlns:webflow="http://www.springframework.org/schema/webflow-config"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schem...-beans-3.0.xsd
    http://www.springframework.org/schema/aop http://www.springframework.org/schem...ng-aop-3.0.xsd
    http://www.springframework.org/schema/webflow-config http://www.springframework.org/schem...config-2.0.xsd
    http://www.springframework.org/schema/faces http://www.springframework.org/schem...-faces-2.0.xsd
    http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">

    <context:annotation-config></context:annotation-config>

    <faces:flow-builder-services id="flowBuilderService" />

    <webflow:flow-registry id="flowRegistry"
    base-path="/WEB-INF/flows" flow-builder-services="flowBuilderService">
    <webflow:flow-location-pattern value="**/*-flow.xml" />
    </webflow:flow-registry>

    <webflow:flow-executor id="flowExecutor"
    flow-registry="flowRegistry">
    <webflow:flow-execution-listeners>
    <webflow:listener ref="flowListener" />
    </webflow:flow-execution-listeners>
    </webflow:flow-executor>

    <bean class="org.springframework.faces.webflow.JsfFlowHa ndlerAdapter">
    <property ref="flowExecutor" name="flowExecutor" />
    </bean>

    <bean class="org.springframework.webflow.mvc.servlet.Flo wHandlerMapping">
    <property name="flowRegistry" ref="flowRegistry"></property>
    <property name="order" value="0"></property>
    </bean>
    <bean id="flowListener"
    class="org.springframework.faces.webflow.FlowFaces ContextLifecycleListener">
    </bean>


    </beans>






    Web.xml:-


    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="3.0" 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_3_0.xsd">

    <!-- <listener> <listener-class>com.upen.listener.StrartUpListener</listener-class>
    </listener> -->
    <context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>
    classpath:applicationContext.xml
    </param-value>
    </context-param>


    <display-name></display-name>
    <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>

    <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.REFRESH_PERIOD</param-name>
    <param-value>1</param-value>
    </context-param>
    <filter>
    <filter-name>charEncodingFilter</filter-name>
    <filter-class>org.springframework.web.filter.CharacterEnco dingFilter</filter-class>
    <init-param>
    <param-name>encoding</param-name>
    <param-value>UTF-8</param-value>
    </init-param>
    <init-param>
    <param-name>forceEncoding</param-name>
    <param-value>true</param-value>
    </init-param>
    </filter>
    <filter-mapping>
    <filter-name>charEncodingFilter</filter-name>
    <url-pattern>/*</url-pattern>
    </filter-mapping>
    <listener>
    <listener-class>org.springframework.web.context.ContextLoade rListener</listener-class>
    </listener>
    <!-- <servlet> <servlet-name>Resources Servlet</servlet-name> <servlet-class>org.springframework.js.resource.ResourceServ let</servlet-class>
    <load-on-startup>0</load-on-startup> </servlet> <servlet-mapping> <servlet-name>Resources
    Servlet</servlet-name> <url-pattern>/resources/*</url-pattern> </servlet-mapping> -->

    <servlet>
    <servlet-name>Spring MVC Dispatcher Servlet</servlet-name>
    <servlet-class>org.springframework.web.servlet.DispatcherSe rvlet</servlet-class>
    <init-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>classpath:applicationContext.xml</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
    </servlet>
    <servlet-mapping>
    <servlet-name>Spring MVC Dispatcher Servlet</servlet-name>
    <url-pattern>/spring/*</url-pattern>
    </servlet-mapping>
    <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>*.faces</url-pattern>
    </servlet-mapping>


    <welcome-file-list>
    <welcome-file>index.html</welcome-file>
    </welcome-file-list>



    </web-app>



    faces-config.xml:-



    <?xml version='1.0' encoding='UTF-8'?>
    <faces-config 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_2_0.xsd"
    version="2.0">

    <application>
    <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
    </application>

    </faces-config>




    where am i gone wrong in the configuration.

    please help me in this regards..

    thanks in advance
Working...
X