HTML Attributes
- HTML elements can have attributes
- Attributes provide additional information about an element
- Attributes are always specified in the start tag
- Attributes come in name/value pairs like: name="value"
Below is an alphabetical list of some attributes often used in HTML:
Attribute | Description |
---|---|
alt | Specifies an alternative text for an image |
disabled | Specifies that an input element should be disabled |
href | Specifies the URL (web address) for a link |
id | Specifies a unique id for an element |
src | Specifies the URL (web address) for an image |
style | Specifies an inline CSS style for an element |
title | Specifies extra information about an element (displayed as a tool tip) |
No comments:
Post a Comment