[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Displaying Images using MSXML

Subject: RE: Displaying Images using MSXML
From: "Hewko, Doug" <Doug.Hewko@xxxxxxxxxxxxxxx>
Date: Wed, 15 Aug 2001 07:26:01 -0400
displaying images using xslt
The problem is that MSXML (4.0 might, but not earlier version) does not
support the <xsl:output="html"/> declaration. <xsl:output="html"> requires
1999/XSL/Transform

Here's another way to try your image:
<img>
<xsl:attribute name="src">
<xsl:value-of select="filename"/>
</xsl:attribute>
</img>


-----Original Message-----
From: Alexander Gutman [mailto:gutman@xxxxxxxxxxxxxxx]
Sent: August 15, 2001 2:41 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  Displaying Images using MSXML


Hello.

Sean Kelly wrote:
> a newbie question using MSXML.
> i'm wondering how i would go about transforming an xml file that holds 
an
> image's filename, to display that image. eg,
> 
> <?xml version="1.0"?>
> 
> <images>
>     <picture>
>         <filename>sunflower.jpg</filename>
>         <text>a photgraph of a sunflower</text>
>     </picture>
>     <picture>
>         <filename>starfish.gif</filename>
>         <text>a photgraph of a starfish</text>
>     </picture>
> </images>
> 
> can anyone point me in the right direction on how i acheive this. i
> understand that an image in XSL the <IMG> tag needs to be closed ie. 
<IMG
> SRC="starfish.gif"/>

Actually, I do not what's the problem.
The image should be displaied (in a clients' browser)
if you do what you say. :-)
So, what kind of help do you need?

How to get a filename from your source?
Then use an appropriate XPath expression; e.g.,
"(/images/picture/filename)[1]" returns the first filename.

How to obtain the desired output with <IMG>'s?
Then code as you say, with the filename substituted
by your expression in "{...}".

How to make those tags "unclosed"?
Then specify <xsl:output method="html"/>.

What else? :-)

-- 
Alexander E. Gutman

 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

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.