Generated Servlet Error: cannot find symbol
843840Dec 25 2009 — edited Dec 25 2009I'm trying to authenticate user login using two jsp pages. I'm getting following error.
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable userName
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable uname
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable passwrd
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable pwd
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
4 errors
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
root cause
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable userName
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable uname
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable passwrd
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
An error occurred at line: 38 in the jsp file: /Auth2.jsp
Generated servlet error:
C:\Users\omi\.netbeans\5.5.1\apache-tomcat-5.5.17_base\work\Catalina\localhost\Authetication2\org\apache\jsp\Auth2_jsp.java:107: cannot find symbol
symbol : variable pwd
location: class org.apache.jsp.Auth2_jsp
if(uname.equals(userName) && pwd.equals(passwrd))
^
4 errors
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
org.apache.jasper.compiler.AntCompiler.generateClass(AntCompiler.java:249)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:303)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)