Explore a little.C ProgrammingC++HTMLVisual BasicSystem AnalysisE-CommerceBCA Notes
LEARN SOMETHING NEW

Disable button in Html

Read4BCA learning libraryFree access

Disable button in Html

Disable Button

Button is used to do some action when a user clicks it.
To make it disable, we can define disable attribute as true. No clicking is allowed in disabled button.


Example:

<!DOCTYPE html>
<html>
<head>
<title>Button</title>
</head>

<body>
<button>Normal button</button>
<button disabled="true">Disable button</button>
</body>
</html>

Output of this code will look like this:

Disable button in Html example

This lesson preserves the original Read4BCA material. Some programming examples use older tools and syntax. View original page.