Prefixed Namespaces Declaration

  • Usage:

    A prefixed namespace is considered to apply to the current and all child elements and attributes that have been declared specifying the same prefix.

  • Notation:

    <pre:name xmlns:pre="" pre:attname="whatever">
  • Prefixed namespace values can be redeclared.

  • pre:name - is called a QName.

  • Only since XML 1.1 is it allowed to undeclare prefixed namespaces using 'xmlns:pre=""'.

  • The prefix functions only as a placeholder for a namespace uri.

    The prefix is not significant, although it is not recommended different prefixes can be defined in the same document mapping to the same namespace uri.

  • Constraints:

    Prefixes beginning with the three-letter sequence x, m, l, in any case combination, are reserved for use by XML and XML-related specifications.