HTML Global Attributes

In this tutorial, you will learn Global Attributes which are common for all HTML elements. The global attributes assist by both standard and non-standard elements.
The global attributes can be use with all elements, even it may not have any effect on m…


This content originally appeared on DEV Community and was authored by elinabey

HTML Global AttributesIn this tutorial, you will learn Global Attributes which are common for all HTML elements. The global attributes assist by both standard and non-standard elements.
The global attributes can be use with all elements, even it may not have any effect on many elements.

HTML defines many attributes that are common to all elements. These attributes may be specified on all elements, with some exceptions where it is not suitable. Like

section of the document E.g , <script>, <base> etc.

HTML Global Attributes are:

Attributes Value Description
Contenteditable true/false It confirm whether the content within an element is editable.
class classname It is used to give the class name for the element. It is mostly use with the CSS stylesheet.
accesskey character It is used to create keyboard shortcuts for the element.
data-* somevalue It is used to save element-specific private data that can be retrieve by Javascript.
contextmenu menu_id It describe the id for the element that is used as a context menu  for an element.
draggable true/false/auto It defines either the content within an element is portable or not using Drag and Drop API.
dropzone copy/move/link It defines the action is taken on the dragged element when it is dropped, ¬¬ such as whether it is copied, moved or linked.
id id It defines a unique id for the element. It can be use with CSS and JavaScript.
style style It is used to apply inline CSS to the element.
spellcheck true false It defines either the content should be checked for spelling errors or not.
title text It is used to give the title, or some extra information about the element.
translate yes/no It defines whether the content of the element should be translated when the web  page is localized or not.

I shared this post from HTML Global Attributes you can read in detail from there.

If you have any question please discuss below help to improve. Thank you.


This content originally appeared on DEV Community and was authored by elinabey


Print Share Comment Cite Upload Translate Updates
APA

elinabey | Sciencx (2021-12-22T16:55:37+00:00) HTML Global Attributes. Retrieved from https://www.scien.cx/2021/12/22/html-global-attributes/

MLA
" » HTML Global Attributes." elinabey | Sciencx - Wednesday December 22, 2021, https://www.scien.cx/2021/12/22/html-global-attributes/
HARVARD
elinabey | Sciencx Wednesday December 22, 2021 » HTML Global Attributes., viewed ,<https://www.scien.cx/2021/12/22/html-global-attributes/>
VANCOUVER
elinabey | Sciencx - » HTML Global Attributes. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/12/22/html-global-attributes/
CHICAGO
" » HTML Global Attributes." elinabey | Sciencx - Accessed . https://www.scien.cx/2021/12/22/html-global-attributes/
IEEE
" » HTML Global Attributes." elinabey | Sciencx [Online]. Available: https://www.scien.cx/2021/12/22/html-global-attributes/. [Accessed: ]
rf:citation
» HTML Global Attributes | elinabey | Sciencx | https://www.scien.cx/2021/12/22/html-global-attributes/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.