Sp 141

From Htmlpedia
Jump to: navigation, search

OpenSP: ID ... already defined

Cause:

An "id" is a unique identifier. Each time this attribute is used in a document it must have a different value. If you are using this attribute as a hook for style sheets it may be more appropriate to use classes (which group elements) than id (which are used to identify exactly one element).

Example:

Bad<span id="name1"> <span id="name1">
Good<span id="name1"> <span id="name2">

Solution:

Use an unique ID or a class name.

References: