2

Is there a way, in Eclipse, to enable some kind of code check for Javascript inside a JSP? I have some code between <script> tags and when a syntax error occurs I cannot easily find where the error is... This is very annoying...

NOTE in Window > Preferences > Validation I enabled Client-side Javascript validator, JSP Content validator and JSP Syntax validator...

5
  • I'm pretty sure JEE Package (the one with WTP) has some JS validation, cannot check out at the moment. Which packages do you have? Commented May 22, 2012 at 8:16
  • 1
    @BigMike I have the JEE Package (v3.7)... the JS validation works for .js files, but it seems not working for code in JSP. But, I'm not sure if the problem depends on some configuration I set... What can I check? Commented May 22, 2012 at 8:21
  • First thing that comes to my mind is to check JSP editor's options and global Validators' options. Commented May 22, 2012 at 8:29
  • I just verified what you say, it doesn't seem to validate mine as well! But I somehow don't notice them. Commented May 22, 2012 at 8:33
  • @adarshr probably I noticed that because I'm a bad javascript programmer... :D Commented May 22, 2012 at 8:36

1 Answer 1

1
  1. Right click your project

  2. Select Properties -> Builders

  3. Check the "JavaScript Validator" (By default, It should be)

Sign up to request clarification or add additional context in comments.

1 Comment

What if there is no "JavaScript Validator" in the list? (it is a maven project in my case)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.