[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] Escape caracters


Subject: RE: [xsl] Escape caracters
From: "Passin, Tom" <tpassin@xxxxxxxxxxxx>
Date: Fri, 28 May 2004 10:30:35 -0400

> From: SMITH Neil [mailto:neil.smith@xxxxxxxx] 

> How come I get these character references in the HTML file I 
> am generating then? Is there something I forgot to specify 
> during translation or something I forgot in the XSL file?
> 

The serializer would output a character reference when the encoding it
is using does not support the character in question.  The only thing you
could change would be the encoding specified in the xsl:output element.
But there is probably no reason to worry about it.  A browser will
usually display what you want, unless the font it is using does not have
a glyph for the character.  In that cse, it could not display the
character no matter how it was encoded.

Why do you care whether there are character references in the html
output?  Is it just to make it easier for you to read when you look at
the source?

Cheers,

Tom P

> 
> -----Original Message-----
> From: Passin, Tom [mailto:tpassin@xxxxxxxxxxxx] 
> Sent: jeudi, 27. mai 2004 16:35
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: RE: [xsl] Escape caracters
> 
> > From: SMITH Neil [mailto:neil.smith@xxxxxxxx]
> 
> & q u o t e ; and & a m p ; (spaces added) are built into xml 
> (along with three others) by its specification and are 
> understood by all xml parsers. Things like & # 8 2 2 2 ; 
> (which are called "character
> references") are also defined by the xml specification.  HTML 
> also understands them.  So there is nothing special to do.  
> HTML-specific entities like & n b s p ; are specific to html 
> and xhtml. 


Current Thread
Keywords