Passing JSP parameter to javascript won't work in IE8!

Posted by Ronen on Stack Overflow See other posts from Stack Overflow or by Ronen
Published on 2010-05-17T08:38:34Z Indexed on 2010/05/17 8:40 UTC
Read the original article Hit count: 314

Could really use with some help here...

I've got a servlet that generates an XML string (relatively long) which I then pass to a javascript variable in a forwarded jsp file: $(document).ready(function() { ... var itXML = <% out.print((String)request.getAttribute("xml"));%> ; ... }

This seems to work just fine in Firefox but when I run the same project on IE8 I get a syntax error for this line.

Any Ideas?

Thanks!

© Stack Overflow or respective owner

Related posts about jsp

Related posts about JavaScript