[Home] [By Thread] [By Date] [Recent Entries]


Richard Tobin scripsit:

> In XML 1.0, this is valid:
> 
>  <!DOCTYPE foo [
>  <!ELEMENT foo ANY>
>  <!ATTLIST foo att NMTOKENS #IMPLIED>
>  <!ENTITY b 'foo&#xD;bar'>
>  ]>
>  <foo att="&b;"/>
> 
> but the corresponding document with &#x85; instead of &#xD; will
> be invalid in 1.1.

Note that in both this case and Richard's other (well-formed only) case,
the character reference has to be inside an entity declaration to work:

<!DOCTYPE foo [
  <!ELEMENT foo ANY>
  <!ATTLIST foo att NMTOKENS #IMPLIED>
  ]>
<foo att="foo&#xD;bar">

is not valid in either 1.0 or 1.1 (the attribute value contains seven
characters of which the fourth is a CR).

-- 
Some people open all the Windows;       John Cowan
wise wives welcome the spring           jcowan@r...
by moving the Unix.                     http://www.reutershealth.com
  --ad for Unix Book Units (U.K.)       http://www.ccil.org/~cowan
        (see http://cm.bell-labs.com/cm/cs/who/dmr/unix3image.gif)

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member