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

Re: xml:space preserve on element converted to html t

Subject: Re: xml:space preserve on element converted to html textarea encoding issue
From: Karl Stubsjoen <kstubs@xxxxxxxxx>
Date: Tue, 7 Jun 2011 09:29:21 -0700
Re:  xml:space preserve on element converted to html  t
So I converted writing the textarea out using CDATA sections and still
the tag is collapsed!  I was certain that this would not be the case,
so that is a little confusing.  So then I thought maybe I can sneak
the &nbsp; into the output in my closing textarea like this:

<xsl:text disable-output-escaping="yes"><![CDATA[&nbsp;</textarea>]]></xsl:text>

And this does work.  Although, the non-breaking space character isn't
really what I want either, I really need <textarea></textarea> with no
white space and the tag not collapsed.

So the dilemna with the encoding is this:  the master stylsheet is
generating either an FO or HTML.  I've been writing everything out to
FO as UTF-8, so now I would need to switch between the two, but can
not, not without calling two different templates, one to produce HTML
and the other to produce FO.  As is, the system calling the stylesheet
is passing a param specifiying either of the two output types.

I did test US-ACII encoding and that works great two.  So given the
nature of my system (1 stylesheet) am I stuck writing out the textarea
the long way as I have?

Karl..

On Tue, Jun 7, 2011 at 8:59 AM, David Carlisle <davidc@xxxxxxxxx> wrote:
> On 07/06/2011 16:54, Karl Stubsjoen wrote:
>> Perhaps the better thing
>> to do is to shove the tags into the result from a CDATA section
>
> you can't have "better thing" and "CDATA section" in the same sentence on
> this list or the word "tag" for that matter.
>
> There is nothing wrong with your result file, just with the way you are
> viewing it. If setting up whatever you are using to view to understand utf-8
> is tricky, just tell XSLT to generate the file in some other encoding such
> as
> <xsl:output encoding="US-ASCII"/>
>
> David
>
>
> ________________________________________________________________________
> The Numerical Algorithms Group Ltd is a company registered in England
> and Wales with company number 1249803. The registered office is:
> Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.
>
> This e-mail has been scanned for all viruses by Star. The service is
> powered by MessageLabs.
> ________________________________________________________________________
>



-- 
Karl Stubsjoen
MeetScoresOnline.com
(602) 845-0006

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-2011 All Rights Reserved.