Subject: Re: [xsl] E [Xerces] Attribute value "1" of type ID must be an NCName when namespaces are enabled. From: Michael Ludwig <mlu@xxxxxxxxxxxxx> Date: Thu, 13 Aug 2009 15:00:54 +0200 |
The message means exactly what it says. For bizarre historical reasons that few people remember, XML requires that an attribute value declared as being of type ID has the same syntax as an XML name - so it cannot start with a digit.
Bizarre historical reasons is exactly what I'm interested in! Quite often, they don't find entrance in the documentation, but live on only in anecdotal camp fire talk. I'd be glad if any of the few people who remember could point out what these reasons are.
At first, I found it odd that a simple integer value did not qualify for ID-ness as per the XML spec. Then, becoming aware of the fact that there is only one ID table per document, I realized it is a useful convention to *prefix* ID values according to the type of object they refer to, the prefix stepping in as a substitute for the table, so that there can be an object HH123 but also BB123. This is when the restriction mentioned above stopped bothering me.
-- Michael Ludwig
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] E [Xerces] Attribute valu, Michael Kay | Thread | Re: [xsl] E [Xerces] Attribute valu, Eliot Kimber |
RE: [xsl] E [Xerces] Attribute valu, Michael Kay | Date | Re: [xsl] E [Xerces] Attribute valu, Eliot Kimber |
Month |