HTML 5 <span> Tag
Example
A text with a span element that is styled with CSS:
<p>My mother has <span style="color:lightblue">light blue</span> eyes.</p> |
View it » |
Definition and Usage
The <span> tag is used to group inline-elements in a document.
The <span> tag provides no visual change by itself.
The <span> tag provides a way to add a hook to a part of a text or a part of a
document.
When the text is hooked in a span element you can add styles to the content, or
manipulate the content with for example JavaScript.
Differences Between HTML 4.01 and HTML 5
NONE
Tips and Notes
Tip: Use the <span> tag to group inline-elements to format them with styles.
Standard Attributes
The <a> tag also supports the Standard Attributes in HTML 5.
Event Attributes
The <a> tag also supports the Event Attributes
in HTML 5.
|