cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Naegeli Margrit <margrit.naeg...@ecofin.ch>
Subject RE: Problem with variables
Date Thu, 19 Oct 2000 14:10:34 GMT
If I get you, then you'd have the same value twice in your xml, which imo is
unnecessary.

You can always access the value with the full path from anywhere in the xsl.
I recommend reading up on XPath.

btw, what you're sending is the xsl, not xml, so it seems all a bit
confusing to me.

Regards, Maggie

> -----Original Message-----
> From: Kai.Rehlen@pass-consulting.com
> [mailto:Kai.Rehlen@pass-consulting.com]
> Sent: Thursday, October 19, 2000 3:57 PM
> To: cocoon-users@xml.apache.org
> Subject: AW: Problem with variables
> 
> 
> Sorry that's not exactly what I mend,
> 
> I would like to access the variable in a xml file so that I 
> can surround it
> in a tag.
> Is this clear ? :-)
> 
> -----Urspr√ľngliche Nachricht-----
> Von: Konstantin Piroumian [mailto:KPiroumian@flagship.ru]
> Gesendet am: Donnerstag, 19. Oktober 2000 14:43
> An: cocoon-users@xml.apache.org
> Betreff: Re: Problem with variables
> 
> Do you mean this:
> 
> <xsl:value-of select="$ID"/>?
> 
> Kot.
> 
> ----- Original Message -----
> From: <Kai.Rehlen@pass-consulting.com>
> To: <cocoon-users@xml.apache.org>
> Sent: 19 ??????? 2000 ?., ??????? 16:29
> Subject: Problem with variables
> 
> 
> > Hi everybody,
> >
> > I know that this isue was on the list before, but I just 
> cant find it in
> the
> > archive. So please give me a hint.
> >
> > Below you see some code. My problem is how to retrieve the 
> variable "ID"
> > outside the <option> tag.
> > Thats all.
> > Thanky you
> >
> > Kai
> >
> >
> >
> > <?xml version="1.0"?>
> > <xsl:stylesheet version="1.0"
> > xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> > >
> > <xsl:template match="/">
> >
> > <body bgcolor="orange">
> >
> > <form id="Level5" action="../request.xml" method="post"
> > target="_top">
> >
> > <select name="K5" style="width=120"
> > onchange="form.submit()">
> > <optgroup label="category 5">
> > <option value="0">select</option>
> > <xsl:for-each select="page / ROWSET / ROW">
> > <xsl:variable name="ID"><xsl:value-of
> > select="CATID"/></xsl:variable>
> > <option value="{$ID}">
> > <xsl:value-of
> > select="NAME"></xsl:value-of>
> > </option>
> >
> > </xsl:for-each>
> > </optgroup>
> > </select>
> > </form>
> > </body>
> > </xsl:template>
> >
> > </xsl:stylesheet>
> >
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> > For additional commands, e-mail: cocoon-users-help@xml.apache.org
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 

Mime
View raw message