You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-dev@jakarta.apache.org by bu...@apache.org on 2004/07/13 12:11:39 UTC
DO NOT REPLY [Bug 30068] New: -
Wrong behaviour of x:out inside x:forEach
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=30068>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=30068
Wrong behaviour of x:out inside x:forEach
Summary: Wrong behaviour of x:out inside x:forEach
Product: Taglibs
Version: 1.1.0
Platform: All
OS/Version: All
Status: NEW
Severity: Normal
Priority: Other
Component: Standard Taglib
AssignedTo: taglibs-dev@jakarta.apache.org
ReportedBy: flaviotordini@tiscali.it
hi all,
inside a x:forEach loop, i put an x:out that evaluates an XPath expression on a
document which is not same of the x:forEach.
The x:out seems to behave strangely. Take a look at following JSP:
=======================
<%@ taglib prefix="x" uri="http://java.sun.com/jsp/jstl/xml" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<c:import url="sample.xml" varReader="r">
<x:parse var="sample" doc="${r}"/>
</c:import>
<x:forEach select="$sample/sample/link">
<c:set var="link">
<x:out select="@href"/>
</c:set>
<c:import url="${link}" varReader="r2">
<x:parse var="sample2" doc="${r2}"/>
</c:import>
<!-- *** this does not work *** -->
<x:out select="$sample2/sample2/text"/>
<!-- this does work, but i think it is not correct -->
<x:out select="$sample2/text"/>
</x:forEach>
======================
sample.xml:
======================
<sample>
<link href="sample2.xml"/>
</sample>
======================
sample2.xml:
======================
<sample2>
<text>this is just a test!</text>
</sample2>
======================
I'm using JSTL 1.1, Jakarta Taglib Standard 1.1.0, Tomcat 5.0.25 (same problem
on both linux and windows)
flavio
---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-dev-help@jakarta.apache.org