content (HTML attribute)
| Depr. | Version |
|---|---|
| No | HTML 2 |
| IE5.5+ | FF1+ | SA1.3+ | OP9.2+ | CH2+ |
|---|---|---|---|---|
| Full | Full | Full | Full | Full |
Syntax
content="string"
Description
content
is a required attribute. It’s this part of the meta
element that contains the actual meta information, which is defined by the
name attribute.
Example
Here, the
content attribute contains a list of categories
that the document relates to:
<meta name="categories" content="work, projects, current"/>
Value
The value of
content varies in accordance with the value of the
name attribute. It may be a simple summary of the
document, a comma-separated list of words or values, a person’s name, or
any string of characters.
Compatibility
| Internet Explorer | Firefox | Safari | Opera | Chrome | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 5.5 | 6.0 | 7.0 | 8.0 | 1.0 | 1.5 | 2.0 | 3.0 | 3.5 | 1.3 | 2.0 | 3.1 | 4.0 | 9.2 | 9.5 | 10.0 | 2.0 |
| Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full | Full |
Full support is provided for the meta
element—all browsers expose a document’s meta information via the Document
Object Model.