You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by Andre Lei <an...@runhere.com> on 2000/07/14 20:17:34 UTC

should xalan be escaping characters in this case?

I have the following XML and XSL adapted from
http://www.zvon.org/HTMLonly/XSLTutorial/Examples/Example62/exampleInOne.htm
l:

---XML---
<?xml version="1.0"?>

<xslTutorial >

<HTML>
<HEAD>
<TITLE>HTML</TITLE>
</HEAD>
<BODY>
<H1> HTML output </H1>
Žížala Å¡nek kočka paÅTez bečka mÄ>Å¡ec výr
</BODY>
</HTML>

</xslTutorial>


---XSL---
<?xml version="1.0"?>

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

<xsl:output method="html" encoding="UTF-8"/>
<xsl:template match="/">
<xsl:copy-of select="/xslTutorial/*"/>
</xsl:template>

</xsl:stylesheet>


---XALAN RESULT ABRIDGED---
<HTML>
<HEAD>
<TITLE>HTML</TITLE>
</HEAD>
<BODY>
<H1> HTML output </H1>
Ž&iacute;žala Å¡nek kočka paÅTez bečka mÄ>Å¡ec v&yacute;r
</BODY>
</HTML>

---jClark's XT RESULT---
<HTML>
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<TITLE>HTML</TITLE>
</HEAD>
<BODY>
<H1> HTML output </H1>
Žížala Å¡nek kočka paÅTez bečka mÄ>Å¡ec výr
</BODY>
</HTML>



Xalan seems to escape some characters whereas jClark's XT does not. I don't
want escaping to be performed here.

Also, notice that XT writes the <META> as well. This isn't necessarily
desired either.

Which one is the correct behaviour?

Thanks in advance,

Andre