xsl-list
[Top] [All Lists]

RE: [xsl] Mysterious 0utput Escaping

2008-02-23 02:21:43
In the context of XML, escaping a character means replacing the character by
an entity reference or character reference, for example replacing < by &lt;
or " by &quot;. (Why this is called "escaping" is essentially historical;
it's an analogy with the use of escape sequences in ASCII-based line
protocols, for example the use of a sequence like "ESC [ G" to set a
dot-matrix printer into italics mode).

So "output escaping" means turning special characters such as "<" appearing
in the output of a transformation into their escaped representations such as
"&lt;".

disable-output-escaping="yes" suppresses this behaviour.

You never need to say disable-output-escaping="no", because it is the
default and almost invariably the right setting. I've often wondered if the
language designers chose a long name for the attribute in the hope that
people wouldn't use it carelessly; in practice I have seen some evidence
that beginners don't know what output escaping is and therefore think it
might be a good idea to switch it off.

Michael Kay
http://www.saxonica.com/


-----Original Message-----
From: Marroc [mailto:marrocdanderfluff(_at_)yahoo(_dot_)co(_dot_)in] 
Sent: 22 February 2008 11:03
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] Mysterious 0utput Escaping

Hi all,

I also want to know the meaning of "output escaping", as in a 
dictionary definition, because I can't relate it to any use 
of those words in their normal, everyday sense. Does it mean 
that we allow the output 'to escape'.
It's also, by default, used as a double-negative:
disable-output-escaping="no" which is silly really - 
output-escaping="yes they are"??? Can anyone help?

Richard



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>