求救:Unable to compile class for JSP

筱伟 2009-03-08 06:02:52
错误信息:
org.apache.jasper.JasperException: Unable to compile class for JSP:

An error occurred at line: 29 in the jsp file: /adjust.jsp
requset cannot be resolved
26: %>
27: <body bgcolor="#FFFFFF" text="#000000">
29: String tempname=requset.getParameter("un");
30: String temppass=request.getParameter("ps");
31: tempname=change(tempname);
32: temppass=change(temppass);


Stacktrace:
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:92)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:423)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:317)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:282)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:586)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html;charset=gb2312">
</head>
<%!
public String change(String a)
{
try
{
String temp=a;
byte[] temp2=temp.getBytes("ISO8859-1");
String temp3=new String(temp2);
return temp3;
}
catch(Exception e)
{
}
return"null";
}
%>
<%
String username="admin";
String password="admin";
%>
<body bgcolor="#FFFFFF" text="#000000">
<%
String tempname=requset.getParameter("un");
String temppass=request.getParameter("ps");
tempname=change(tempname);
temppass=change(temppass);
if(tempname.equals("admin")&&temppass.equals("admin"))
{
session.putValue("un",tempname);
response.sendRedirect("choose.jsp");
}
else
{
response.sendRedirect("relogin.jsp");
}
%>
</body>
</html>
...全文
57 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

81,090

社区成员

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

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