在实际开发中,往往会由于action的过多导致struts.xml的臃肿。因此需要划分struts.xml
<?xml version="1.0" encoding="GBK"?> <!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.1//EN" "http://struts.apache.org/dtds/struts-2.1.dtd"> <struts> <include file="struts-user.xml"/> <include file="struts-customer.xml"/> </struts>
注意配置的包的名字不能相同