xsl-list
[Top] [All Lists]

Re: XSLT Recursive Templates

2003-06-27 02:53:42



XSLT does not recorgnise carriage returns, hence i was
forced to use the following recursive template:

You are mistaken. an XML parser normalises various line end conventions
to a single #10 character. XSLT does recognise that.

It does not of course convert text between blank lines into paragraph
elements, but then neither did your suggested alternative.
To say that one piece of code is quicker than another that does
something entirely different isn't very informative.

Of course if you are in a situation where you want "<pre>" style
formatting, with all white space preserved, and no autonmatic line
wrapping, then that's what you should do, either by using pre, or
equivalent css properties, which is what your example did.

If however what you want is paragraphs that act as html paragraphs (and
this is the normal situation, I find), then that is not what you should
do.

David


________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>