No result defined for action xxx and result xxx 5C

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

LoginAction.java
package com.action;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts2.ServletActionContext;

import com.dao.UserDao;
import com.model.User;
import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;

public class LoginAction extends ActionSupport{
private static final long serialVersionUID = 1L;

private String id;
private String pwd;

public String getId() {
    return id;
}

public void setId(String id) {
    this.id = id;
}

public String getPwd() {
    return pwd;
}

public void setPwd(String pwd) {
    this.pwd = pwd;
}

public String execute() throws Exception {
    // TODO Auto-generated method stub
    return ERROR;
}
}

struts.xml
<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.5//EN" "http://struts.apache.org/dtds/struts-2.5.dtd">



/index.jsp
/userlogin.jsp


表单:

登录



    <input type="password" id="pwd" placeholder="Password" required/>
</fieldset>
<fieldset id="actions">
    <input type="submit" id="submit" value="登 录"/>
    <a href="">忘记密码?</a><a href="">Register</a>
</fieldset>

/s:form

1个回答

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问