Attributes and XML
Added 26 Jul 2008
If you've written HTML, you've almost certainly used attibutes without even realizing it. For example, the image tag requires the use of at least one attribute, the src attribute in order to display any images. But with HTML, if you include an attribute that is incorrect or invalid, the browsers will ignore it.
In XML, like HTML, an attribute is a part of an element that
provides additional information about that element. You might think of
an attribute as an adjective describing the element it is within. For
example, if you have an element "dog", it might have an attribute
color="white":
Attributes are formed in name=value pairs. Thus, in XML, you
would never write