<filter> <filter-name>struts2Filter</filter-name> <filter-class> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter </filter-class> </filter> <filter-mapping> <filter-name>struts2Filter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> </filter>
<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN" "http://struts.apache.org/dtds/struts-2.3.dtd"> <struts> <package name="隨意取個惟一名" namespace="/" extends="struts-default"> <action name="訪問名" class="action類的全路徑名" method="action中的方法名"> <result name= "action方法返回的字符串">/所需跳轉頁面名</result> <result name= "faliter">/faliter.jsp</result> </action> </package> </struts>
struts開發jar包下載web
連接:https://pan.baidu.com/s/1rDewNUm7yuSfbl9R_NNP9w 密碼:rudxapache