Source

webwork / webapps / showcase / src / webapp / WEB-INF / web.xml

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>

    <display-name>WebWork Showcase Application</display-name>

    <filter>
        <filter-name>webwork-cleanup</filter-name>
        <filter-class>com.opensymphony.webwork.dispatcher.ActionContextCleanUp</filter-class>
    </filter>

    <filter>
        <filter-name>webwork</filter-name>
        <filter-class>com.opensymphony.webwork.dispatcher.FilterDispatcher</filter-class>
    </filter>

    <filter>
        <filter-name>sitemesh</filter-name>
        <filter-class>com.opensymphony.module.sitemesh.filter.PageFilter</filter-class>
    </filter>

    <filter-mapping>
        <filter-name>webwork-cleanup</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>sitemesh</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>webwork</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>


    <listener>
        <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>


	<servlet>
		<servlet-name>jspSupportServlet</servlet-name>
		<servlet-class>com.opensymphony.webwork.views.JspSupportServlet</servlet-class>
		<load-on-startup>10</load-on-startup>
	</servlet>
	
	<servlet>
		<servlet-name>freemarkerServlet</servlet-name>
		<servlet-class>com.opensymphony.module.sitemesh.freemarker.FreemarkerDecoratorServlet</servlet-class>
		<init-param>
			<param-name>TemplatePath</param-name>
			<param-value>/</param-value>
		</init-param>
		<init-param>
			<param-name>default_encoding</param-name>
			<param-value>ISO-8859-1</param-value>
		</init-param>
		<load-on-startup>11</load-on-startup>
	</servlet>


    <!-- SNIPPET START: dwr -->

    <servlet>
        <servlet-name>dwr</servlet-name>
        <servlet-class>org.directwebremoting.servlet.DwrServlet</servlet-class>
        <init-param>
            <param-name>debug</param-name>
            <param-value>true</param-value>
        </init-param>
        <init-param>
            <param-name>org.directwebremoting.extend.AccessControl</param-name>
            <param-value>com.opensymphony.webwork.dwr.WebWorkDwrAccessControl</param-value>
        </init-param>
    </servlet>

    <servlet-mapping>
        <servlet-name>dwr</servlet-name>
        <url-pattern>/dwr/*</url-pattern>
    </servlet-mapping>

    <!-- END SNIPPET: dwr -->
    
    
    <servlet-mapping>
    	<servlet-name>freemarkerServlet</servlet-name>
    	<url-pattern>*.dec</url-pattern>
    </servlet-mapping>
    

    <!-- SNIPPET START: example.velocity.filter.chain
        <filter>
            <filter-name>webwork-cleanup</filter-name>
            <filter-class>com.opensymphony.webwork.dispatcher.ActionContextCleanUp</filter-class>
        </filter>
        <filter>
            <filter-name>sitemesh</filter-name>
            <filter-class>com.opensymphony.webwork.sitemesh.VelocityPageFilter</filter-class>
        </filter>
        <filter>
            <filter-name>webwork</filter-name>
            <filter-class>com.opensymphony.webwork.dispatcher.FilterDispatcher</filter-class>
        </filter>

        <filter-mapping>
            <filter-name>webwork-cleanup</filter-name>
            <url-pattern>/*</url-pattern>
        </filter-mapping>
        <filter-mapping>
            <filter-name>sitemesh</filter-name>
            <url-pattern>/*</url-pattern>
        </filter-mapping>
        <filter-mapping>
            <filter-name>webwork</filter-name>
            <url-pattern>/*</url-pattern>
        </filter-mapping>
    END SNIPPET: example.velocity.filter.chain -->

    <!-- SNIPPET START: example.freemarker.filter.chain
    <filter>
        <filter-name>webwork-cleanup</filter-name>
        <filter-class>com.opensymphony.webwork.dispatcher.ActionContextCleanUp</filter-class>
    </filter>
    <filter>
        <filter-name>sitemesh</filter-name>
        <filter-class>com.opensymphony.webwork.sitemesh.FreeMarkerPageFilter</filter-class>
    </filter>
    <filter>
        <filter-name>webwork</filter-name>
        <filter-class>com.opensymphony.webwork.dispatcher.FilterDispatcher</filter-class>
    </filter>

    <filter-mapping>
        <filter-name>webwork-cleanup</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>
    <filter-mapping>
        <filter-name>sitemesh</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>
    <filter-mapping>
        <filter-name>webwork</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>
    END SNIPPET: example.freemarker.filter.chain -->

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

    <taglib>
        <taglib-uri>sitemesh-page</taglib-uri>
        <taglib-location>/WEB-INF/sitemesh-page.tld</taglib-location>
    </taglib>

    <taglib>
        <taglib-uri>sitemesh-decorator</taglib-uri>
        <taglib-location>/WEB-INF/sitemesh-decorator.tld</taglib-location>
    </taglib>

</web-app>