Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Attribute has no value

 
ray bond
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello there,
I have an html page which has form of firstname,lastname,email
etc. when user clicks submit action is
<form action="process.jsp" method=post>
but when I try to run this is tomcat and submit form
I get following error,
org.apache.jasper.compiler.ParseException: C:\jspdoc\process.jsp(13,36) Attribute has no value
void org.apache.jasper.runtime.JspServlet.service(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
void javax.servlet.http.HttpServlet.service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
void org.apache.tomcat.core.ServletWrapper.handleRequest(org.apache.tomcat.core.Request, org.apache.tomcat.core.Response)
void org.apache.tomcat.core.ContextManager.service(org.apache.tomcat.core.Request, org.apache.tomcat.core.Response)
void org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(org.apache.tomcat.service.TcpConnection, java.lang.Object[])
can anybody tell me why this ,"Attribute has no value" error comes ,what should I do , when this error comes?
thanks
 
Frank Carver
Sheriff
Posts: 6920
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This looks like a syntax error in your JSP code. Please post your "process.jsp".
 
ray bond
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello sheriff , thanks for your reply , here is my
process.jsp....
<jsp:useBean id="formhandler" class="jspbeans.FormHandler" scope="request" />
<jsp:setProperty name="formhandler" property="*" />
<%
if (formhandler.validate()) {
%>
<jsp:forward page="formreport.jsp" / >
<% } else { %>
<jsp:forward page="retry.jsp" />
<% } %>
it uses formhandler class , whats wrong with it?
thanks
 
Frank Carver
Sheriff
Posts: 6920
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Strange. The error message seems to be pointing at line 13, column 36 - which is not there in the code you posted. Did your file have some wierd non-printable character(s) in it? Mixed line-ends?
 
Jason Menard
Sheriff
Posts: 6450
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's hard to tell exactly, but without seeing any other code, if I had to guess I would sau it has to do with the line:
<jsp:setProperty name="formhandler" property="*" />
Is it possible that your form is sending a field that the FormHandler isn't set up to deal with?
J
 
ray bond
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello there , finally I solved this,
I think you have to restart tomcat after modifying your code of your application , otherwise it would continue to show same errors everthough you have modified them, am I right?
thanks
 
Frank Carver
Sheriff
Posts: 6920
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes! Tomcat has a peculiar implementaion of class reloading. Most Tomcat users get into the habit of restarting the server to make sure it is using the latest versions of everything. I use Resin and find that it is much better at this.
 
Daniel Santos
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
**** SOLVED THIS! ****
in my case, I forgot to close the double quotes of the value in an import tag
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic