Return the value of the abbr attribute of a <th> element with id "myTh":
The result of x could be:
The abbr property sets or returns the value of the abbr attribute.
The abbr attribute specifies a shorter version of the content in a header cell.
Note: The abbr attribute has no visual effect in ordinary web browsers, but can be used by screen readers.
The abbr property is supported in all major browsers.
Return the abbr property:
Set the abbr property:
Value | Description |
---|---|
text | Specifies a short description of the header cell content |
Return Value: | A String, representing a short description of the header cell content |
---|
Change the value of the abbr attribute of a <th> element with id "myTh":
HTML reference: HTML <th> abbr attribute