XML Names

The XML 1.0 Recommendation places restrictions on the characters that may be used in legal XML names and imposes tighter restrictions on the characters that may be used as the first character in an XML name.

Initial Characters of XML Names

In English, the initial character of an XML name must be either a letter (from A to Z—both upper- and lowercase are legal), the colon character (:), or the underscore character (_).

Tip

Avoid the colon character as the first character in an XML name. Using that character is legal but could cause confusion when you create XML documents using elements from several XML namespaces (described in Chapter ...

Get Sams Teach Yourself XML in 10 Minutes now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.