HTML button Tag disabled Attribute Tutorial

In this section, we will learn what disabled attribute is and how it works.

What is disabled Attribute in HTML <button> Tag?

The disabled attribute is used to disable a button!

After using this attribute on a <button> element, that element will be disabled and that means it’s no-longer clickable.

HTML disabled Attribute in <button> Tag Syntax:

<button disabled> </button>

<button> Tag disabled Attribute Values

The disabled attribute does not take a value. All we need is to do is to set this attribute in the opening tag of HTML <button>

Example: using disabled attribute in HTML <button> tag

See the Pen using disabled attribute in HTML <button> tag by Omid Dehghan (@odchan1) on CodePen.


Top Technologies