Page Loading...
Run
Break Lines
Result
<!DOCTYPE html> <html> <head> <style> /*Write CSS Here*/ </style> </head> <body> <button id='myBtn'>My Button</button> <br><br> <button onclick='disableBtn()'>Disable 'My Button'</button> <button onclick='enableBtn()'>Enable 'My Button'</button> <script> var myBtn = document.getElementById('myBtn'); function disableBtn(){ myBtn.disabled = true; // Disabled } function enableBtn(){ myBtn.disabled = false; // Enabled } </script> </body> </html>