struts不执行方法

mimi5211 mimi5211 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
这是我的ACTION:
public ActionForward selectall(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response)
throws Exception
{
System.out.println("before");

UserinfoActionForm userform=(UserinfoActionForm) form;
try {
request.setAttribute("all", DAOFactory.getUserinfoInstance()
.QueryAll());
} catch (Exception e) {

}
System.out.println("after");
return mapping.findForward("list");
}
这是我的JSP:
<a href="user.do?status=selectall">用户管理</a><p>
这是我的配置文件:
<action name="UserinfoForm" path="/user" attribute="UserinfoForm" input="/errors.jsp"
type="cn.telmedia.cmsa.userinfo.action.UserinfoAction" scope="request" parameter="status">
<forward name="success" path="/success.jsp" contextRelative="true"></forward>
<forward name="fail" path="/success.jsp" contextRelative="true"></forward>
<forward name="insertdo" path="/insert_do.jsp"></forward>
<forward name="update" path="/update.jsp"></forward>
<forward name="updatedo" path="/update_do.jsp"></forward>
<forward name="deletedo" path="/delete_do.jsp" contextRelative="true"></forward>
<forward name="list" path="/user/user_list.jsp" contextRelative="true"></forward>
</action>
为什么我点这个的时候<a href="user.do?status=selectall">用户管理</a><p>不执行ACTION里的方法啊?一运行就到了input上的页面上啊?
...全文
评论 7
收藏 已收藏
分享
返回顶部
mimi5211
Java 51,407 成员 86,129 内容