Skip to main content
AI Assist is now on Stack Overflow. Start a chat to get instant answers from across the network. Sign up to save and share your chats.

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 24
    As of jQuery 1.6 you should use $("#target :input").prop("disabled", true); Commented Mar 8, 2013 at 9:49
  • 5
    Someone should edit the answer with the updated method -- this is just bad information at this point. Commented Oct 17, 2013 at 18:25
  • and in a submit() callback, using $(this), how to do that? Commented Jan 8, 2015 at 14:15
  • 2
    @OlivierPons $(this).closest('form').find('input').prop('disabled', true);. Not sure if you can consolidate that better, I'm still rather noobish at jQuery. Commented Jan 14, 2015 at 13:11