View Single Post
  #1 (permalink)  
Old November 26th, 2013, 10:27 AM
hfmanson hfmanson is offline
Registered User
Points: 5, Level: 1
Points: 5, Level: 1 Points: 5, Level: 1 Points: 5, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Nov 2013
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default codepoints-to-string XML characters

Hello,

XML 1.0 documents are not allowed to contain control characters other than U+0009, U+000A, U+000D. The XPath function codepoints-to-string follows this restriction. However when using <xsl:output method="text"/> codepoints-to-string still doesn't allow other control characters. Shouldn't codepoints-to-string allow any Unicode character when the output is text?

Example:
Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="2.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:xs="http://www.w3.org/2001/XMLSchema"
    exclude-result-prefixes="xsl xs">

<xsl:output method="text" encoding="ISO-8859-1"/>

<xsl:template match="text()|@*">
</xsl:template>

<xsl:template match="/">
<xsl:value-of select="codepoints-to-string((16))"/>
</xsl:template>

</xsl:stylesheet>
Kind regards,

Henri Manson
mansoft.nl