• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tomcat 5 giving error on commented out JSP page

 
Ali Ekber
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am running Tomcat 5.5 on Linux, and it started acting very wierd. I have a commented out piece of Java code somewhere in my JSP, and I am getting an error.

The actual error is an SQL exception, but the code is commented out, so it shouldn't be executed. This is very strange. Any ideas?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65120
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Perhaps it's not as commented out as you think it is?
 
IM Mahesh
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Syntax for JSP comments is: <% comments %>
If you are using the tag <!-- --> to comment out your java code then it will not work because it is html syntax.
 
IM Mahesh
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry for a little type mistake.
jsp comments tag is: <%-- comments --%> and not <% comments %> which i mentioned in previous reply.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic