Eclipse: What are these JSP errors?

I inherited a web application, and when configured in Eclipse it shows errors in a specific JSP.

Errors do not have a description associated with them in the "Problems" view, and clicking on them leads me to the top of the JSP, where the red underline error appears half through the line as follows:

<%@ page erro[rPage="/basicError.j]sp" %> [<%@ page import="javax.s]ervlet.ServletContext" %> 

Imagine the red error β€œerror” under parts enclosed in square brackets with [] (bold, etc. will not be displayed in this code segment, and I cannot show the code at all if it is not in the code segment, therefore using [and].

Other examples of errors:

enter image description here




Clicking on the red β€œX” to the left of the lines does nothing.

I tried re-importing the project, updating, checking, moving lines, etc., but I always get this error.

Does anyone know what is going on here?

+9
eclipse jsp
Jun. 04 '10 at 14:45
source share
4 answers

Run it. It works? Then again the built-in Eclipse built-in JSP validator, which is epic fail . Just disable it in the workspace settings via Web> JSP Files> Validation> scroll to the lowest level and set all EL scan parameters to Ignore. Also, in the main validation rule, clear all the checkboxes associated with the JSP. This, however, does not seem to eliminate all warnings / errors, but at least minimizes annoyance.

+7
Jun 04 '10 at 2:55 a.m.
source share
β€” -

I tried disabling jsp validation but nothing worked, so I tried the following and it worked.

  • Select all code from jsp.
  • copy it to a text editor
  • remove everything from your jsp.
  • Save your jsp. [All red lines should disappear at this step].
  • Copy and paste the code back into jsp.
  • Save your jsp again.
  • Done.
+1
Apr 08 '13 at
source share

The solution that worked for me is given in this answer .

Go to project properties> Runtime Targets> Check the box for the runtime (Apache Tomcat 7 in my case).

It's all. Just create a project now and everything will be fine

+1
Mar 04 '16 at 20:41
source share

Right click your project -> Build Path -> Configure Build Path

Step 1: On the Library tab, you must have the correct version of the JRE system library (for example: JRE System Library [JRE7]) and the server library (for example: Apache tomcat V7.0) If not, then click add library β†’ JRE System library β†’ select installed jre version also add library β†’ server runtime β†’ select installed server

Step 2: Forward and Export tab, make sure that the JRE System Library and server library are installed, click OK

0
Apr 16 '14 at 2:33
source share



All Articles