HTML <span> tag
When writing in HTML, the <span> tag is used as an inline container for grouping or phrasing content. It is useful when you want to change the language of a section of text, or its styling, via the use of CSS or the <style> tag. The following sections contain information about this tag, including an example of it in use, as well as related attributes and browser compatibility.
<p>I drive an <span style="color:orange">orange</span> car.</p>
I drive an orange car.
Within an HTML tag, an attribute dictates certain aspects of an HTML element. Attributes are made up of a name and value pair. While the <span> tag does not have any unique attributes, it does utilize all of the standard attributes.
|All versions||All versions||All versions||All versions||All versions|