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

<br />'s double-space after XSL transformation

Subject: <br />'s double-space after XSL transformation
From: Kathryn.Grant@xxxxxxxxxxxxxxxxx
Date: Wed, 19 Jun 2002 17:38:31 -0700
xslt br double
Hi all,

Got a strange question.  I have an xhtml document which contains a few
<br/>'s.  When the xhtml document is viewed in the browser,
pre-transformation, the <br/>'s behave normally, inserting a line break.

However, after I transform the document, all the <br/>'s become TWO line
breaks--in other words, they insert a double space as if they were </p>'s.
Can anyone tell me why, or suggest how I can get the <br/>'s to insert just
one line break after the transformation?

I'm using the following XSL--pretty simple:

<?xml version="1.0" encoding="UTF-8"?>

<xsl:stylesheet
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:xhtml="http://www.w3.org/1999/xhtml"
    version="1.0">

<xsl:output method="html" encoding="UTF-8"/>

	<xsl:template match="node() | @*">
		<xsl:copy>
			<xsl:apply-templates select="node() | @*"/>
		</xsl:copy>
	</xsl:template>

</xsl:stylesheet>

The transformation is done with the following javascript code:

<script type="text/javascript">
// Load XML
var xml = new ActiveXObject("MSXML2.DOMDocument")
xml.async = false
xml.load("3-xhtml.htm")

// Load the XSL
var xsl = new ActiveXObject("MSXML2.DOMDocument")
xsl.async = false
xsl.load("manager.xsl")

// Transform
document.write(xml.transformNode(xsl))

TIA,
Kathryn

 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.