java - why the "${}" tag in jsp output as a string -
i want import js file in jsp way
<script type="text/javascript" src="${pagecontext.request.contextpath}/js/layout/jquery-ui.js"></script> but when browse deployed page ,i found ${pagecontext.request.contextpath}part showed on browsers string,the code above try find js file in ${pagecontext.request.contextpath}/js/layout/ folder instead ofxxx/js/layout/
my developing environment "myeclipse10.5+tomcat7.0+jdk7.0"
check jsp isn't configured ignore el page directive
<%@ page ... iselignored="true" %> or, check web.xml hasn't turned el off jsps with
<jsp-config> ... <el-ignored>true</el-ignored> ... </jsp-config>
edit :
also, check web.xml's <web-app> version 2.4 or higher. add following web.xml workaround (if nothing else works) :
<jsp-config> <jsp-property-group> <url-pattern>*.jsp</url-pattern> <el-ignored>false</el-ignored> </jsp-property-group> </jsp-config>
Comments
Post a Comment