Subject: Re: displaying images From: "Betty L. Harvey" <harvey@xxxxxxxxxxxxxxxxx> Date: Fri, 10 Dec 1999 17:01:48 -0500 (EST) |
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
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
displaying images, Matt Lowe | Thread | Re: displaying images, Brett McLaughlin |
Re: XSLT Question: Inserting a DOCT, John Robert Gardner | Date | Re: displaying images, Brett McLaughlin |
Month |