The <span> element serves as an inline container utilized to annotate a segment of text or a portion of a document.
While the <span> element doesn’t necessitate specific attributes, style, class, and id are frequently applied.
When paired with CSS, the <span> element facilitates the styling of text segments.
Example
<p>My mother has <span style=”color:blue;font-weight:bold;”>blue</span> eyes and my father has <span style=”color:darkolivegreen;font-weight:bold;”>dark green</span> eyes.</p> |