Posted By

artaserse on 03/22/12


Tagged

input jquery disable


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

allprowebdesigns
BrockSamsom


disable input with Jquery


 / Published in: jQuery
 

simply disable an input (type=text) using Jquery.

  1. //jQuery < 1.6
  2. jQuery('input[name=name_of_the_input]').attr('disabled',true)
  3.  
  4. //jQuery >= 1.6
  5. jQuery('input[name=name_of_the_input]').prop('disabled',true)

Report this snippet  

You need to login to post a comment.