Can someone test this example and share the results?
http://timothypowell.net/blog/?p=23
When I do:
var myVar = '<% request.getContextPath(); %>';
alert(myVar);
I get : '<% request.getContextPath(); %>'.
Removing the enclosing single quotes from '<% request.getContextPath(); %>'; gives syntax error. How can I use the scrptlet or expresion inside a js function?
EDIT: this link has an explanation that helped me:
http://www.codingforums.com/showthread.php?t=172082