[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: [xsl] problem of result returned by variable
Subject: Re: [xsl] problem of result returned by variable From: David Carlisle <davidc@xxxxxxxxx> Date: Tue, 22 Aug 2006 15:07:00 +0100 |
The first time you call the doc template, "." is "/" so <xsl:with-param name="varReq1" select=".//DEP = $requete/DEP and .//ANI= $requete/ANI"/> is true just if there is a DEP anywhere in the document that is equal to any of the elements $requete/DEP and if there is a ANI anywhere in the document that is equal to any of the elements $requete/ANI However in your test, "." is an element A <xsl:when test=".//DEP = $requete/DEP and .//ANI= $requete/ANI"> so the test is true just if there is a DEP anywhere in the decendents of this A element that is equal to any of the elements $requete/DEP and if there is a ANI anywhere in the decendents of this A element that is equal to any of the elements $requete/ANI <!-- MY PROBLEM : WHEN I HAVE : test=".//DEP = $requete/DEP and .//ANI= $requete/ANI" the RESUALT is CORRECT WHEN I MAKE test="$varReq1" THE result is NOT CORRECT INSPITE OF content OF varReq1 vraiable is .//DEP = $requete/DEP and .//ANI= $requete/ANI My Question why the result is not same as the result when test=".//DEP = $requete/DEP and .//ANI= $requete/ANI" --> since the two expressions are comparing different sets of elements there is no reason to expect to get the same result, but since you haven't shown your input or what test you want to make, i can't suggest what your coding should be. David
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] problem of result returned b, corine amel zayanie | Thread | [xsl] Constructing documents from m, Steve |
RE: [xsl] Saxon removes namespace i, Michael Kay | Date | Re: [xsl] Calling mutator java meth, David Carlisle |
Month |