Got it working just fine. Make sure you have version 1.1.+ of Orion..1.0 had
a problem with the access to WEB-INF dir.

1. Copy struts.jar into your WEB-INF/lib dir or your web-app
2. Copy struts.tld into WEB-INF dir of your web-app
3. Copy the web.xml text below into your web.xml, overwriting whatever is
necessary and keeping anything else you need that you may already have
(different mappings, etc)

<?xml version="1.0"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">

<web-app>
        <servlet>
                <servlet-name>action</servlet-name>
                <display-name>action</display-name>
                <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
                <init-param>
                        <param-name>debug</param-name>
                        <param-value>0</param-value>
                </init-param>
                <init-param>
                        <param-name>forward</param-name>
                        
<param-value>org.apache.struts.action.ActionForward</param-value>
                </init-param>
                <init-param>
                        <param-name>config</param-name>
                        <param-value>/WEB-INF/action.xml</param-value>
                </init-param>
                <init-param>
                        <param-name>application</param-name>
                        
<param-value>org.apache.struts.action.ActionResources</param-value>
                </init-param>
                <init-param>
                        <param-name>mapping</param-name>
                        
<param-value>org.apache.struts.action.ActionMappingBase</param-value>
                </init-param>
                <init-param>
                        <param-name>nocache</param-name>
                        <param-value>false</param-value>
                </init-param>
        </servlet>
        <servlet-mapping>
                <servlet-name>action</servlet-name>
                <url-pattern>*.do</url-pattern>
        </servlet-mapping>
        <welcome-file-list>
                <welcome-file>index.jsp</welcome-file>
        </welcome-file-list>
        <taglib>
                <taglib-uri>/WEB-INF/struts.tld</taglib-uri>
                <taglib-location>/WEB-INF/struts.tld</taglib-location>
        </taglib>
</web-app>


That is all I did. Works great for me. Oh..I am using extension mapping,
which means a form looks like this:

<form action="/MyActionName.do" method="post">


That way any link or form action with a .do in the name of it, is sent to
the ActionServlet of Struts.


Reply via email to