XHTML attributes

       You can add attributes to some XHTML tags. Some are mandatory, some are optional. Example:

<img src="ship.gif" border="0" />
       The tag is called img. The two attributes here are src and border. If an img tag doesn't have the attribute src, we don't really go anywhere - src is used to point to the picture supposed to be shown here. But border is optional - if you don't write anything, a default value applies. But if you use border, you can say how wide a border you want around the picture.
       Note that all values (ship.gif and 0 in the example) should be in quotation marks.
       Other examples of attributes are the href attribute for the a tag, and that most tags might have the attributes class and id.

Concept last updated: 05/09 2004.

Relations

has

Other sources

XHTML XHTML attributes XHTML attributter

Libellus