tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bb...@brakus.com
Subject x:set var
Date Mon, 13 Jan 2003 18:03:06 GMT
All,

For the life of me, I cannot figure out why the following examples produce
different results.  Many thanks in advance if anyone can help.

I'm importing an XML doc with the following:

<x:parse var="reports">
	<c:import url="reports.xml"/>
</x:parse>

If I use

<x:out select="$reports//report[@shortname='biweekly']/id" />

I get the expected result, "157."

However, if I use

<x:set var="reportID" select="$reports//report[@shortname='biweekly']/id"
/>

<c:out value="${reportID}" />

I get, "[[id: null]]".

The xPath syntax is obviously correct, as I'm getting the expected result
with the x:out tag.  So, any idea what I'm doing wrong when I try to expose
the same result in the variable reportID?

Thanks again,
Buck Bell


--
To unsubscribe, e-mail:   <mailto:taglibs-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:taglibs-user-help@jakarta.apache.org>


Mime
View raw message