0% found this document useful (0 votes)
2 views10 pages

HTML Attributes

The document lists various HTML attributes along with the HTML elements they belong to. It includes attributes for forms, inputs, scripts, and global attributes, while also noting which attributes are not supported in HTML5. This serves as a reference for developers to understand the usage and applicability of different HTML attributes.

Uploaded by

Aiatul Islam
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views10 pages

HTML Attributes

The document lists various HTML attributes along with the HTML elements they belong to. It includes attributes for forms, inputs, scripts, and global attributes, while also noting which attributes are not supported in HTML5. This serves as a reference for developers to understand the usage and applicability of different HTML attributes.

Uploaded by

Aiatul Islam
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

6/21/2019 HTML Attributes

Attribute Belongs to

accept <input>

accept-charset <form>

accesskey Global Attributes

action <form>

align Not supported in HTML 5.

alt <area>, <img>, <input>

async <script>

autocomplete <form>, <input>

autofocus <button>, <input>, <select>, <textarea>

autoplay <audio>, <video>

bgcolor Not supported in HTML 5.

border Not supported in HTML 5.

charset <meta>, <script>

checked <input>

cite <blockquote>, <del>, <ins>, <q>

class Global Attributes

[Link] 1/10
6/21/2019 HTML Attributes

color Not supported in HTML 5.

cols <textarea>

colspan <td>, <th>

content <meta>

contenteditable Global Attributes

controls <audio>, <video>

coords <area>

data <object>

data-* Global Attributes

datetime <del>, <ins>, <time>

default <track>

defer <script>

dir Global Attributes

dirname <input>, <textarea>

disabled <button>, <fieldset>, <input>, <optgroup>, <option>, <select>, <textarea>

download <a>, <area>

draggable Global Attributes

[Link] 2/10
6/21/2019 HTML Attributes
dropzone Global Attributes

enctype <form>

for <label>, <output>

form <button>, <fieldset>, <input>, <label>, <meter>, <object>,<output>, <select>, <textarea>

formaction <button>, <input>

headers <td>, <th>

height <canvas>, <embed>, <iframe>, <img>, <input>, <object>, <video>

hidden Global Attributes

high <meter>

href <a>, <area>, <base>, <link>

hreflang <a>, <area>, <link>

http-equiv <meta>

id Global Attributes

ismap <img>

kind <track>

label <track>, <option>, <optgroup>

lang Global Attributes

list <input>

loop <audio>, <video>

[Link] 3/10
6/21/2019 HTML Attributes

low <meter>

max <input>, <meter>, <progress>

maxlength <input>, <textarea>

media <a>, <area>, <link>, <source>, <style>

method <form>

min <input>, <meter>

multiple <input>, <select>

muted <video>, <audio>

name <button>, <fieldset>, <form>, <iframe>, <input>, <map>, <meta>, <object>, <output>, <param>, <select>, <textar

novalidate <form>

onabort <audio>, <embed>, <img>, <object>, <video>

onafterprint <body>

onbeforeprint <body>

onbeforeunload <body>

onblur All visible elements.

oncanplay <audio>, <embed>, <object>, <video>

oncanplaythrough <audio>, <video>

onchange All visible elements.

onclick All visible elements.

oncontextmenu All visible elements.

[Link] 4/10
6/21/2019 HTML Attributes

oncopy All visible elements.

oncuechange <track>

oncut All visible elements.

ondblclick All visible elements.

ondrag All visible elements.

ondragend All visible elements.

ondragenter All visible elements.

ondragleave All visible elements.

ondragover All visible elements.

ondragstart All visible elements.

ondrop All visible elements.

ondurationchange <audio>, <video>

onemptied <audio>, <video>

onended <audio>, <video>

onerror <audio>, <body>, <embed>, <img>, <object>, <script>, <style>, <video>

onfocus All visible elements.

onhashchange <body>

oninput All visible elements.

oninvalid All visible elements.

[Link] 5/10
6/21/2019 HTML Attributes

onkeydown All visible elements.

onkeypress All visible elements.

onkeyup All visible elements.

onload <body>, <iframe>, <img>, <input>, <link>, <script>, <style>

onloadeddata <audio>, <video>

onloadedmetadata <audio>, <video>

onloadstart <audio>, <video>

onmousedown All visible elements.

onmousemove All visible elements.

onmouseout All visible elements.

onmouseover All visible elements.

onmouseup All visible elements.

onmousewheel All visible elements.

onoffline <body>

ononline <body>

onpagehide <body>

onpageshow <body>

onpaste All visible elements.

onpause <audio>, <video>

[Link] 6/10
6/21/2019 HTML Attributes
onplay <audio>, <video>

onplaying <audio>, <video>

onpopstate <body>

onprogress <audio>, <video>

onratechange <audio>, <video>

onreset <form>

onresize <body>

onscroll All visible elements.

onsearch <input>

onseeked <audio>, <video>

onseeking <audio>, <video>

onselect All visible elements.

onstalled <audio>, <video>

onstorage <body>

onsubmit <form>

onsuspend <audio>, <video>

ontimeupdate <audio>, <video>

[Link] 7/10
6/21/2019 HTML Attributes

ontoggle <details>

onunload <body>

onvolumechange <audio>, <video>

onwaiting <audio>, <video>

onwheel All visible elements.

open <details>

optimum <meter>

pattern <input>

placeholder <input>, <textarea>

poster <video>

preload <audio>, <video>

readonly <input>, <textarea>

rel <a>, <area>, <link>

required <input>, <select>, <textarea>

reversed <ol>

rows <textarea>

[Link] 8/10
6/21/2019 HTML Attributes

rowspan <td>, <th>

sandbox <iframe>

scope <th>

selected <option>

shape <area>

size <input>, <select>

sizes <img>, <link>, <source>

span <col>, <colgroup>

spellcheck Global Attributes

src <audio>, <embed>, <iframe>, <img>, <input>, <script>, <source>, <track>, <video>

srcdoc <iframe>

srclang <track>

srcset <img>, <source>

start <ol>

step <input>

style Global Attributes

tabindex Global Attributes

target <a>, <area>, <base>, <form>

title Global Attributes

[Link] 9/10
6/21/2019 HTML Attributes

translate Global Attributes

type <a>, <button>, <embed>, <input>, <link>, <menu>, <object>, <script>, <source>, <style>

usemap <img>, <object>

value <button>, <input>, <li>, <option>, <meter>, <progress>, <param>

width <canvas>, <embed>, <iframe>, <img>, <input>, <object>, <video>

wrap <textarea>

[Link] 10/10

You might also like