How to Disable or Renable a Button in Javascript Using jQuery Library (PROP + ATTR) Methods Full Tutorial For Beginners

You are currently viewing How to Disable or Renable a Button in Javascript Using jQuery Library (PROP + ATTR) Methods Full Tutorial For Beginners

 

Welcome folks today in this post we will be talking about how to disable or renable a button in javascript using popular library called as jquery. All the code snippets used will be given below.

 

 

 

Disabling a Button in jQuery

 

 

Now to disable a button using jquery we will use the typical method of jquery called as attr to disable or renable a button

 

 

 

 

 

Renable Button in jQuery

 

 

Now renabling a button is very easy you just need to do the opposite

 

 

 

 

 

Second Method to Disable or Renable a Button

 

 

We can also use prop method in jquery to do the same thing

 

 

 

 

 

 

 

Leave a Reply