struts配置:
<struts-config>
<form-beans>
<form-bean name="aa" type="com.li.aa"></form-bean>
</form-beans>
<global-exceptions />
<global-forwards />
<action-mappings>
<action path="cc" type="com.li.bb" name="aa" parameter="command">
<forward name="success" path="/Success.jsp"></forward>
<forward name="fail" path="/Fail"></forward>
</action>
</action-mappings>
<message-resources parameter="com.li.ApplicationResources" />
</struts-config>jsp登陆界面:
<form action="/cc.do" method="post">
用户名:<input name="username" type="text" size="15" />
密 码:<input name="password" type="password" size="15" />
<input type="submit" value="登陆"/>
</form>
错误:HTTP Status 404 - /cc.do--------------------------------------------------------------------------------type Status reportmessage /cc.dodescription The requested resource (/cc.do) is not available.
--------------------------------------------------------------------------------Apache Tomcat/6.0.29
<struts-config>
<form-beans>
<form-bean name="aa" type="com.li.aa"></form-bean>
</form-beans>
<global-exceptions />
<global-forwards />
<action-mappings>
<action path="cc" type="com.li.bb" name="aa" parameter="command">
<forward name="success" path="/Success.jsp"></forward>
<forward name="fail" path="/Fail"></forward>
</action>
</action-mappings>
<message-resources parameter="com.li.ApplicationResources" />
</struts-config>jsp登陆界面:
<form action="/cc.do" method="post">
用户名:<input name="username" type="text" size="15" />
密 码:<input name="password" type="password" size="15" />
<input type="submit" value="登陆"/>
</form>
错误:HTTP Status 404 - /cc.do--------------------------------------------------------------------------------type Status reportmessage /cc.dodescription The requested resource (/cc.do) is not available.
--------------------------------------------------------------------------------Apache Tomcat/6.0.29
<form action="cc.do?method" method="post">或
<form action="/cc" method="post"> 都可以的