Preserving entities?

D. Alvarado

Usenet Archive
Joined
Apr 25, 2002
Messages
63
Reaction score
0
Hi,
I cannot seem to preserve my XML entities when I transform to HTML. For example, I want to transform a document containing

ā

and I would like that exact string to appear in
the resulting HTML. Unfortunately, during the
XML -> HTML, the "ā" gets
converted to an actual character. When I tried using

<![CDATA[ā]]>

the following was in the HTML file

&amp;#257;

What is your advice regarding how to preserve
these entities?

Much thanks, - Dave
 

Patrick TJ McPhee

Usenet Archive
Joined
Apr 2, 2000
Messages
269
Reaction score
0
% For example, I want to transform a document containing % % ā % % and I would like that exact string to appear in % the resulting HTML.

Try adding

encoding='ISO-8859-1'

as an attribute of the xsl:eek:utput element.
 

Kenneth Stephen

Usenet Archive
Joined
Dec 29, 2003
Messages
36
Reaction score
0
D. Alvarado said:
Hi,
I cannot seem to preserve my XML entities when I transform to HTML. For example, I want to transform a document containing

ā

and I would like that exact string to appear in
the resulting HTML. Unfortunately, during the
XML -> HTML, the "ā" gets
converted to an actual character. When I tried using
Dave,

In your xsl:text or xsl:value-of that is actually writing out the value in question, add the following attribute : disable-output-escaping="yes".

Regards,
Kenneth
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
548,208
Messages
3,104,802
Members
249,594
Latest member
henrywalsh

Latest Threads

Top