HTML attributes can be used to better control and access elements, allowing to easier target specific elements with CSS declarations, and to access elements through scripting.
Attributes are added to the opening tag of HTML elements. Unless specified otherwise, attribute values themselves should generally be enclosed in either double quotes (") or single quotes (').
If an attribute value contains double quotes, then you can use single quotes around the attribute value instead.
Attributes are added in the opening tag of HTML elements, beginning with the name of the attribute, followed by the equal sign (=) and finally its quoted value. I.e.: (Name="attribute value")
|style||Used to apply styles.|
|title||Used for tool-tips.|
|class||Used to "group" elements. See also: CSS selectors|
|accesskey||Creates a keyboard shortcut that will focus on the element when pressed.|
|contenteditable||Makes the content of the element editable.|
|hidden||The element is hidden. Similar to display:hidden;|
|lang||Defines the language of the element and it's children.|
|spellcheck||Enables spellcheck of the element.|
The event attributes is used by scripts.
|onclick||Script||A pointer button was clicked.|
|ondblclick||Script||A pointer button was double clicked|
|onmousedown||Script||A pointer button was pressed down|
|onmouseup||Script||A pointer button was released.|
|onmouseover||Script||A pointer was moved onto.|
|onmousemove||Script||A pointer was moved within.|
|onmouseout||Script||A pointer was moved away.|
|onkeypress||Script||A key was pressed and released.|
|onkeydown||Script||A key was pressed down.|
|onkeyup||Script||A key was released.|
|onload||Script||When either the page (use on body), image, or frame loads.|
The Internationalization Attributes.
|dir||ltr|rtl||Direction for text.|