[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
and graphics salad!
Subject: <xsl:choose> <xsl:when> and graphics salad! From: "Medina, Edward" <emedina@xxxxxxx> Date: Tue, 4 Apr 2000 14:44:39 -0400 |
Yeah you read correctly. That's what I'm making, I'm not really making a document, just tossing up some xslt and hoping it would do what I want it to do. No chance. Ok, I'll stop complaining. Here is my problem. I want to be able for xsl to place graphics according to certain metadata (attributes) values (ie right, left, top, bottom) and place the graphics to the right, left, top, or bottom of the paragraph. I thought that I might be able to do that with xsl:choose/when but no. Or at least I haven't broken the code how to do it yet. Of course my problem may not be xsl at all and could be all those <SPAN style=" blah"> that I have been using, but frankly its either that or go with the HTML type (unless someone know of a better way). I can capture the graphics and place them to the right, centered, to the left but I can't make it sit next to a paragraph. I don't mean any arbitrary paragraph but a specific paragraph. You have seen my code before (Yes I know its not pretty but it works), so here it is. <xsl:template match="image"> <xsl:choose> <xsl:when test="contains (@align,'banner')"> </xsl:when> <xsl:when test="contains (@align,'right')"> <SPAN style=" Omited code </SPAN> <xsl:choose> <xsl:when test="contains(text/@...'note')"> <SPAN style=" ommited code <xsl:value-of select="text"/> <SPAN style=" ommited code <IMG > more code ommited </IMG> <xsl:value-of select="illust"/> <xsl:apply-templates /> </SPAN> </SPAN> </xsl:when> </xsl:choose> </xsl:when> even more code ommited <xsl:otherwise> </xsl:otherwise> </xsl:choose> </xsl:template> So why doesn't it capture the text and the graphics and place them side by side? What am I doing wrong. I think I just need to go home and rest. That's probably what I need. However, if you come up with an idea, please feel free to post it. I'll be reading it. Eddy XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: Can I use XSL to convert HTML t, Wendell Piez | Thread | Re: <xsl:choose> <xsl:when> and gra, David Carlisle |
Re: Multiple expressions in xsl:if, David_Marston | Date | Re: "Translate function", David Carlisle |
Month |