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

Carriage Return & # 13 ;

Subject: Carriage Return & # 13 ;
From: Jan Mendling <mendling@xxxxxx>
Date: Tue, 3 Dec 2002 22:31:33 +0100
13
Hello once more, and thanks for the remarks and hints so far.

1. This is my input:
------------------------

<Text>This is a carriage
return</Text>

and I want to identify the carriage return in this Text-Element.


2.a) This is the template I wrote:
-------------------------
<xsl:template name="Text" mode="Text">        
        <xsl:param name="Text"/>        
        <xsl:variable name="UC13">&#13;</xsl:variable>        
        <xsl:choose>
            <xsl:when test="contains($Text,$UC13)">
                <xsl:call-template name="Text">
                    <xsl:with-param name="Text" select="concat(substring-before($Text,'$UC13'),' UC13 ',substring-after($Text,'$UC13'))"/>
                </xsl:call-template>
            </xsl:when>
	</xsl:choose>

2.b) Entities
------------------------
I also tried to declare !Entities before the stylesheet to refer to the Unicode character in the body. It did not work.

3. I got an error when running the script:
-------------------------
C:\Excalibur Home\Path\>java org.apache.xalan.xslt.Process -in LinkTest.xml -xsl textcleanser.xsl
(Location of error unknown)XSLT Error (java.lang.StackOverflowError): null


QUESTION: Is there any way to detect carriage return in the input file? I need to preserve it in the output. I tried < xsl:preserve-space elements="*" >, but it did not show the intended result.

Greetings and Thanks,
Jan Mendling
______________________________________________________________________________
Der Anrufbeantworter fur Ihre E-Mail-Korrespondenz - WEB.DE FreeMail
http://freemail.web.de/features/?mc=021137


 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.