ssh 求助, struts 1.2 版本!
来源:百度知道 编辑:UC知道 时间:2024/06/01 11:41:43
异常信息
org.apache.jasper.JasperException: An exception occurred processing JSP page /form/denglu.jsp at line 15
12: </head>
13:
14: <body>
15: <html:form action="/user?User=userDL">
16: userName : <html:text property="userName" />
17: <br />
18:
From 代码
<html:form action="/user?User=userDL">
userName : <html:text property="userName" />
<br />
userPwd : <html:text property="userPwd" />
<br />
<html:submit value="deng lu" />
</html:form>
Struts 配置
<!-- type="com.xinxi.struts.action.UserAction" -->
<action
attribute="userForm"
input="/form/user.jsp"
name="userForm"
parameter="User"
path="
org.apache.jasper.JasperException: An exception occurred processing JSP page /form/denglu.jsp at line 15
12: </head>
13:
14: <body>
15: <html:form action="/user?User=userDL">
16: userName : <html:text property="userName" />
17: <br />
18:
From 代码
<html:form action="/user?User=userDL">
userName : <html:text property="userName" />
<br />
userPwd : <html:text property="userPwd" />
<br />
<html:submit value="deng lu" />
</html:form>
Struts 配置
<!-- type="com.xinxi.struts.action.UserAction" -->
<action
attribute="userForm"
input="/form/user.jsp"
name="userForm"
parameter="User"
path="
<html:form action="/user.do?User=userDL">
userName : <html:text property="userName" />
<br />
userPwd : <html:text property="userPwd" />
<br />
<html:submit value="deng lu" />
</html:form>
首先加上.do在action中,其次还要指定actionform才可以。
目前看不到你具体的报错信息,应该是只差一个.do
去掉 / ,在一般的JSP中加上 / 表示到了服务器的根目录了
另外 用 html:form不需要加 .do
action="/user.do?...加个.do