日期:2014-05-17  浏览次数:20813 次

strcts2 跳转问题
structS.XML
XML code

<package name="com.gogoosoft" namespace="/" extends="core-default">
    <action name="login" class="com.gogoosoft.action.LoginAction" method="post">
    <result type="dispather">/one.jsp</result>
    </action>
</package>    



index.JSP
Java code

 <form action="login" method="post">
    <input type="text" name="userName">
    <input type="text" name="userPassword"/>
    <input type="submit"/>
    </form>



出错:HTTP Status 404 - No result defined for action com.gogoosoft.action.LoginAction and result success

--------------------------------------------

type Status report

message No result defined for action com.gogoosoft.action.LoginAction and result success

description The requested resource (No result defined for action com.gogoosoft.action.LoginAction and result success) is not available.


------解决方案--------------------
探讨

引用:
引用:

引用:
result的name没有写,默认就是success
method=post,那么就是走的post方法,把你action中的post方法贴出来看看吧


Java code

public String execute() throws ……