• struts基于mvc的开发代码

    <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 1.2//EN" "http://struts.apache.org/dtds/struts-config_1_2.dtd"> <struts-config> <data-sources /> <form-beans > <form-bean name="testForm" type="com.yourcompany.struts.form.TestForm" /> <form-bean name="test1Form" type="com.yourcompany.struts.form.Test1Form" /> <form-bean name="test2Form" type="com.yourcompany.struts.form.Test2Form" /> <form-bean name="test3Form" type="com.yourcompany.struts.form.Test3Form" /> </form-beans> <global-exceptions /> <global-forwards > <forward name="test1" path="/test1.jsp" /> <forward name="test2" path="/test2.jsp" /> <forward name="test3" path="/test3.jsp" /> <forward name="scope" path="/sure.jsp" /> </global-forwards> <action-mappings > <action attribute="testForm" input="/test.jsp" name="testForm" path="/test" scope="request" type="com.yourcompany.struts.action.TestAction" /> <action attribute="test1Form" input="/test1.jsp" name="test1Form" path="/test1" scope="request" type="com.yourcompany.struts.action.Test1Action" /> <action attribute="test2Form" input="/test2.jsp" name="test2Form" path="/test2" scope="request" type="com.yourcompany.struts.action.Test2Action" /> <action attribute="test3Form" input="/test3.jsp" name="test3Form" path="/test3" scope="request" type="com.yourcompany.struts.action.Test3Action" /> </action-mappings> <message-resources parameter="com.yourcompany.struts.ApplicationResources" /> </struts-config>

    5
    71
    243KB
    2009-06-03
    12
上传资源赚积分or赚钱