You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-user@tomcat.apache.org by ma...@quick.co.jp on 2002/10/10 07:55:04 UTC

Does JSTL XML taglibs ignore XMLNamespace of input document?

Hi, I just started learning JSTL, am especially interested in XML-related
taglibs.

I use jakarta-taglibs/standard-1.0.1 on tomcat4.1.3.

I coded the following JSP page

-----------------------------------------------------------------
<%@ taglib uri="/WEB-INF/x.tld" prefix="x" %>
<x:parse var="NoNS"><a><b>boon</b></a></x:parse>
<x:parse var="WithNS"><n:a xmlns:n
="someNamespace"><n:b>baan</n:b></n:a></x:parse>
$NoNS/a/b=<x:out select="$NoNS/a/b"/><br>
$WithNS/a/b=<x:out select="$WithNS/a/b"/><br>
$WithNS/n:a/n:b=<x:out select="$WithNS/n:a/n:b"/>
-----------------------------------------------------------------
The only difference between $NoNS object and $WithNS object is XML
Namespace usage.

I got the following response from the application.
-----------------------------------------------------------------
$NoNS/a/b=boon
$WithNS/a/b=
$WithNS/n:a/n:b=
-----------------------------------------------------------------
I can not get "baan" output.

I do not see how the XPath expression should be written for $WithNS object
using JSTL taglib

I read JSTL specification document and as many resources on the web as I
could find,
and I have a feel that the JSTL specification is not explicit enough how to
deal with
XML namespace used in the input source.

Am I wrong? If I am wrong and the told how to solve this, I would be very
much pleased.


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>