jstl tags do not link with jsp variables
ím trying to add jstl/jsp component to a spring+flex+hibernate project. Im using Tomcat 5, downloaded and added the jakarta-taglibs-standard-1.1.2 dependencies, made some changes to the web.xml, etc... dont want to get drifted away from my current problem, this piece of code:
<c:forEach var="i" begin="1" end="10" step="1">
<c:out value="${i}" />
sip!
<br />
</c:forEach>
At the jsp file, Prints this:
${i} sip!
${i} sip! ${i} sip! ${i} sip! ${i} sip! ${i} sip! ${i} sip! ${i} sip! ${i} sip! ${i} sip!So for what i understand here, the jstl ta开发者_如何学编程g is working, but not the jsp? However, this code:
<%
for(int i=1;i<=10;i++)
{%>
<%=i%><br/>
<%
}
%>
prints this:
1
2 3 4 5 6 7 8 9 10So here, jsp is working with variables.
I never used jsp/jstl before, neither together or separate. However for what i understand, both tags work fine on my setup, how ever they don´t work together, variables are not linking ?? this right ? how can i fix it?
Thank you!
UPDATE: Got it working! problem was on my web.xml, matched the header with the one described here for my version: http://faq.javaranch.com/java/ServletsWebXml.
Hope this helps some one. One meta question, should i answer my own question ? or leave it like this ?
UPDATE: Got it working! problem was on my web.xml, matched the header with the one described here for my version: http://faq.javaranch.com/java/ServletsWebXml.
精彩评论