> On Thu, 2010/03/25, Keary Suska <[email protected]> wrote:
>> Maybe a cool option for NSXML would be to be able to
>> specify the & pound ; sequence and have it map it to
>> whatever.......
 
> My XML is a little rusty but IIRC this is an XML issue, and
> any XML parser would choke. You have to define (or perhaps
> more properly "declare") every named entity other than the
> pre-defined named entities such as &gt;, &lt; and
> &amp;.
>
> I believe you can use numeric references with impunity:
> &#nnn; but make sure it jives with your character
> encoding.

Agreed.  pound is defined in html 4 but not in xhtml,
which has only pre-defined character references for 
amp, lt, gt, apos, and quot
http://www.w3.org/TR/2006/REC-xml11-20060816/#intern-replacement
But in the current mode, they strive to make it difficult 
to put the pieces together, though they may believe they
are clearly doing so here
http://www.w3.org/TR/2006/REC-xml11-20060816/#intern-replacement
here
http://www.w3.org/TR/2006/REC-xml11-20060816/#sec-entexpand
and here
http://www.w3.org/TR/2006/REC-xml11-20060816/#NT-EntityValue

But if you've told it you're using UTF-8 or UTF-16 it
shouldn't need an ampersand escape, since the British
pound sterling symbol is not otherwise used in XML itself;
in which case you just use the Unicode character.  But,
if you want to be compatible with html 4 you've got to
define that character reference.


      
_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to