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

xslt breaks css with a <![CDATA[ <img/> ]]> tag!

Subject: xslt breaks css with a <![CDATA[ <img/> ]]> tag!
From: mark wallace <fadingdust@xxxxxxxxx>
Date: Fri, 8 Sep 2006 22:25:08 -0700 (PDT)
email spam with img tags
It's really simple. I want to throw in arbitrary HTML in the XML
data. Example:
----------------------------------------------------------------
  <element><![CDATA[Name2 <img
src="http://www.google.com/images/logo_sm.gif" height="20px" />
Name]]></element>
----------------------------------------------------------------
transformed with: 
----------------------------------------------------------------
   <div class="box"><xsl:value-of select="element"
disable-output-escaping="yes"/></div>
----------------------------------------------------------------
Well, the image will display (good) but it seems to float:left
(to the edge of the .element div) all the elements before it!!

The example is at: http://philblack.us/mark/flowchart/index.php
compare with (in firefox)
http://philblack.us/mark/flowchart/flow.xml

the index.php is nothing but:
----------------------------------------------------------------
<? $stylesheet = $basepath . "flow1.xsl";
$memofile=$basepath . "flow.xml";
$xmldoc = domxml_open_file($memofile); 
$xsldoc = domxml_xslt_stylesheet_file($stylesheet);
$result =  $xsldoc->process($xmldoc);
echo $result->html_dump_mem(); ?>
----------------------------------------------------------------

Well, what makes it all the more interesting is if you remove
the <img/> tag from the CDATA, oh look! it works like it
should!!

You'll notice I've added 'boundary css' to show the
aligning/spacing of it all. I've tried playing with the
display:inline/block & position:static,relative,absolute. All to
no avail.

Anyone see what I'm saying? Hopefully a solution is out there.

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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.