I am using XLST files to transform XML to XML.
What are valid representation of space?
<xsl:text> </xsl:text>
<xsl:text> </xsl:text>
<xsl:text> </xsl:text>
I am using XLST files to transform XML to XML.
What are valid representation of space?
<xsl:text> </xsl:text>
<xsl:text> </xsl:text>
<xsl:text> </xsl:text>
As it relates to the question, add all the entities that are causing parse errors to the DOCTYPE of your *.xls style sheet.
Now you can use
as you would normally.XML does not have any named entities besides
<
,>
,"
,'
and&
.All other characters can be represented verbatim, given that you declared the right encoding in the XML declaration (e.g.
<?xml version="1.0" encoding="..." ?>
). Declaring UTF-8 is optional, as this is the default anyway.In other words: There is no need to specially escape any character anywhere unless leaving it unescaped would break XML syntax rules (like
<
or&
would).You are of course free to escape any character you want.
These representations are equivalent as far as the resulting document is concerned:
Note that you can declare custom named entities (like
nbsp
) using a DOCTYPE.But given the fact that XML accepts any character that's hardly ever necessary. Especially not when you create the document using a proper tool, like a DOM API.