|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: displaying images
Matt:
This should work where:
<picture file="mygraphic.jpg">
<xsl:template match="picture">
<img>
<xsl:attribute name="src">
<xsl:value-of select="@file"/>
</xsl:attribute>
</img><xsl:apply-templates/>
</xsl:template>
Hope this helps.
Betty
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
Betty Harvey | Phone: 301-540-8251 FAX: 4268
Electronic Commerce Connection, Inc. |
13017 Wisteria Drive, P.O. Box 333 |
Germantown, Md. 20874 |
harvey@xxxxxxxxxx | Washington,DC SGML/XML Users Grp
URL: http://www.eccnet.com | http://www.eccnet.com/xmlug/
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\\/\/
On Fri, 10 Dec 1999, Matt Lowe wrote:
> I am new to XSL programming, and am trying to learn it as I build a new application. We are planning to use XML/XSL to display database results in a browser.
>
> My problem:
> I need to display an image based on the filename from the XML file. I understand that the result tree simply needs to show the html needed to display the file (that being <img src="picture.jpg">)
> However the "picture.jpg" is what is coming in the XML file, and I can't configure the XSL to transform it correctly. Can anyone help?
>
> Thanks
> matt
>
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








