web.xml中配置struts2过滤器配置

<!-- struts2 过滤器 -->
 <filter>
        <filter-name>struts2</filter-name>
        <filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>
    </filter>

    <filter-mapping>
        <filter-name>struts2</filter-name>
        <url-pattern>*.action</url-pattern>
    </filter-mapping>
原文地址:https://www.cnblogs.com/huqin/p/6938013.html