You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Steve Holden <st...@town-index.com> on 2000/11/08 09:32:47 UTC
Dynamic image loading
Hi, I was wondering if someone could point me in the direction of using a
value inside a tag to qualify a path to an image. Here's an example:
<town id=0001>
<title>hello everyone</title>
<dy>4</dy>
</town>
So take a XSL stylesheet with the following:
<img src="../dir/<valueof dy tag>.gif" border="0">
You get the idea, i want the value of dy to add itself to the img tag as to
create a dynamic graphic loading sequence.
Any ideas....
Steve holden
Re: clarification about a concept: Generator
Posted by Ross Burton <ro...@lineone.net>.
On Thu, 9 Nov 2000, Tien Duc Nguyen wrote:
> Hello all,
> I haven't found on the xml-apache site nor on the mailing list
> the answers to these questions:
> what is a generator and a serializer? Can someone please clarify me on this.
A Generator creates (generates) SAX events which describe an XML
document. These events may come from any source, but are typically
produced by scanning a xml file on disk.
A Serializer takes SAX events and turns them into a final output form - be
it a XML text file, HTML, an image (see the SVGSerializer), PDF (via
FOP) etc.
In C1 speak, these are Producers and Formatters.
Ross Burton
clarification about a concept: Generator
Posted by Tien Duc Nguyen <ti...@reevescommunication.com>.
Hello all,
I haven't found on the xml-apache site nor on the mailing list
the answers to these questions:
what is a generator and a serializer? Can someone please clarify me on this.
Thank you,
Tien Duc
R: Dynamic image loading
Posted by Peretta Simone <s....@cbim.it>.
----- Original Message -----
From: Steve Holden <st...@town-index.com>
To: <co...@xml.apache.org>
Sent: Wednesday, November 08, 2000 9:32 AM
Subject: Dynamic image loading
> Hi, I was wondering if someone could point me in the direction of using a
> value inside a tag to qualify a path to an image. Here's an example:
>
> <town id=0001>
> <title>hello everyone</title>
> <dy>4</dy>
> </town>
>
> So take a XSL stylesheet with the following:
>
> <img src="../dir/<valueof dy tag>.gif" border="0">
>
> You get the idea, i want the value of dy to add itself to the img tag as
to
> create a dynamic graphic loading sequence.
>
> Any ideas....
>
>
> Steve holden
>
>
Hi.
Try to use <xsl:element> like this:
<xsl:element name="img">
<xsl:attribute name="src">
<valueof dy tag/>
</xsl:attribute>
....The list of attribute....
</xsl:element>
Re: Dynamic image loading
Posted by Konstantin Piroumian <KP...@flagship.ru>.
This is a pure XSL question and must be posted to the XSL mailing list.
Anyway, it's very easy:
<!-- inside your xsl template for town -->
...
<img border="0">
<xsl:attribute name="src">../dir/<xsl:value-of
select="dy"/>.gif</xsl:attribute>
</img>
...
Kot.
> Hi, I was wondering if someone could point me in the direction of using a
> value inside a tag to qualify a path to an image. Here's an example:
>
> <town id=0001>
> <title>hello everyone</title>
> <dy>4</dy>
> </town>
>
> So take a XSL stylesheet with the following:
>
> <img src="../dir/<valueof dy tag>.gif" border="0">
>
> You get the idea, i want the value of dy to add itself to the img tag as
to
> create a dynamic graphic loading sequence.
>
> Any ideas....
>
>
> Steve holden
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
>