在地址栏里输入http://localhost:8088/StrutsLoginDemo/userLogin.jsp出现异常,大家帮忙看看是什么问题,要怎么改,谢谢!

RUBY_uu 2006-05-19 05:16:32
type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

我的userLogin.jsp代码:
<%@ page language="java"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html"%>

<html>
<html:html locale="true" >
<head>
<title>JSP for userLoginForm form</title>
</head>
<body>
<html:form action="/userLogin">
password : <html:password property="password"/><html:errors property="password"/><br/>
userName : <html:text property="userName"/><html:errors property="userName"/><br/>
<html:submit/><html:cancel/>
</html:form>
</body>
</html>

我的代码有什么问题吗?要怎么改呢?

感激不尽!!
...全文
795 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
wind5131420 2006-05-30
  • 打赏
  • 举报
回复
最近在搞这个,也出现过类似问题,请确定你的struts-config.xml中form bean、form mapping中相关内容是否设置好,还有,你在JSP页面中写的
password : <html:password property="password"/><html:errors property="password"/><br/>
userName : <html:text property="userName"/><html:errors property="userName"/>
中用到的这两个property,也就是password、userName是否在对应的Form中已经定义了?或者定义了你写错了?如果是向导自动生成定义的话,很可能你后面的那个userName就是你自己改错了的,因为我看到向导自动生成的一般好像都是小写的E文子目,中间没怎么有大些E文字母
zhkchi 2006-05-29
  • 打赏
  • 举报
回复
没有错误消息怎么看呢?

可能是action="/userLogin" 这个地方在配置文件没设置好吧
lbianxp 2006-05-29
  • 打赏
  • 举报
回复
如果不是路径错误的话,还要保证truts-html.tld已经导入到项目中。
java_augur 2006-05-29
  • 打赏
  • 举报
回复
后台的代码呢?

58,454

社区成员

发帖
与我相关
我的任务
社区描述
Java Eclipse
社区管理员
  • Eclipse
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧