How to Use the HTML Tag abbr
The abbr
tag in HTML stands for "abbreviation" and is used to define an abbreviation or an acronym. When the mouse hovers over the text enclosed in the abbr
tag, it will display the full version of the abbreviation or acronym as a tooltip.
Usage:
Here is an example of how to use the abbr
tag:
<p>Please submit your report by <abbr title="end of day">EOD</abbr> tomorrow.</p>
When rendered in a browser, the sentence will appear as: "Please submit your report by EOD tomorrow." When the user hovers over "EOD," they will see the tooltip "end of day."
Main Tag Attributes:
Attribute | Description |
---|---|
title | Specifies the full version of the abbreviation or acronym, which will be displayed as a tooltip when the user hovers over the text. |