Subject: Re: [xsl] Lookup tables From: "James A. Robinson" <jim.robinson@xxxxxxxxxxxx> Date: Thu, 15 Mar 2007 18:51:51 -0700 |
Oh, I see I misread your post. I thought you wanted to put the table in the stylesheet, sorry. Can't you just use a normal key lookup? <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:myns="uri.my.namespace" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="text" /> <xsl:key name="Keys" match="Keys/Key" use="@name" /> <xsl:template match="/"> <xsl:apply-templates select="/A/B/C/*"/> </xsl:template> <xsl:template match="Referrer"> <xsl:value-of select="key('Keys', @ref)/@value"/> </xsl:template> </xsl:stylesheet> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - James A. Robinson jim.robinson@xxxxxxxxxxxx Stanford University HighWire Press http://highwire.stanford.edu/ +1 650 7237294 (Work) +1 650 7259335 (Fax)
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Lookup tables, James A. Robinson | Thread | Re: [xsl] Lookup tables, Kamal Bhatt |
Re: [xsl] Lookup tables, Joe Fawcett | Date | Re: [xsl] Lookup tables, Kamal Bhatt |
Month |