| Author |
Message |
|
|
Post subject: JSTL in JavaScript
Posted: Jul 16, 2012 - 10:19 PM
|
|
Joined: Jul 16, 2012
Posts: 3
|
|
Hi,
I am using MyEclipse 10.5 and it seems that I am getting a validation error when there is a JSTL tag within my JavaScript. Is there a way to fix this in the configuration - A sample jsp file is presented below:
<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c" %>
....
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
---
----
<script language="javascript">
var requests = new Array(<c:out value="${command.requestCount}" />);
<c:if test="${command.requestCount > 0}">
I get an error at right here at <c:if> line -- "syntax error on tokens: delete these tokens"
Any help is appreciated. Thank you! |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Jul 17, 2012 - 07:57 AM
|
|

Joined: Nov 11, 2010
Posts: 2154
|
|
sm99,
Sorry that you are seeing this issue. We have a PR filed for this one and the dev team is looking into it.
Alternatively you can use the logical operator 'gt' instead of '>' and see if it works for you. |
_________________ Swapna
MyEclipse Support
|
| |
|
|
|
 |
|
|
Post subject: JSTL in JavaScript
Posted: Jul 17, 2012 - 11:11 PM
|
|
Joined: Jul 16, 2012
Posts: 3
|
|
Thank you for your reply. The gt seems to work but there are other <c:if> instances I think where the validator seems to think of it as an error. I am attaching a txt file(JSP) that seems to have a problem too. Lastly, in JS files, how can we use JSTL tags without
the validator seeing it as an error. Is there a configuration for this? Thanks. |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Jul 18, 2012 - 08:17 AM
|
|

Joined: Nov 11, 2010
Posts: 2154
|
|
sm99,
Thank you for reporting it.The dev team is investigating the issue. I am afraid there is no configuration to omit the JSTL tags from validation.
You can right click on the jsp > MyEclipse > Exclude from Validation . This will not show the errors in the Problem view but the editor will still mark it as error.
Sorry for inconvenience caused. |
_________________ Swapna
MyEclipse Support
|
| |
|
|
|
 |
|
|
Post subject: JSTL in Java Script
Posted: Feb 12, 2013 - 06:23 PM
|
|
Joined: Jul 16, 2012
Posts: 3
|
|
Hi,
I was just wondering if there are any available patches/fixes for this. Thanks! |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Feb 14, 2013 - 08:57 AM
|
|

Joined: Nov 11, 2010
Posts: 2154
|
|
sm99,
Can you please update to MyEclipse 10.7.1 our latest version which released last week and check if you still see the issue ?
Let us know how it works for you. |
_________________ Swapna
MyEclipse Support
|
| |
|
|
|
 |
|
|