Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How do I use jsp variables in jstl?

843838Feb 19 2007 — edited Feb 28 2007
Hi all,

Lets say that I have something like:
 <%
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+ "/Templates/";
%>
and then I want to use this variable in a jstl like this:
<c:import url="<c:out value="${basePath}"/>heading.jsp"/>
why do I get a this response:
[b]Error 500: 404 /%basePath%heading.jsp


I'm using websphere 6.0 to test, is this a websphere problem or it's just not possible for jstl to use jsp variables.

Is there any other way to import jsp variables into jstl?

thanks in advance.......

mike
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 28 2007
Added on Feb 19 2007
7 comments
1,529 views