copenndthagen
copenndthagen

Reputation: 50750

jQuery mouse events on disabled form field

Which jQuery mouse events are actually fired on a disabled form field like a disabled checkbox ?

Upvotes: 0

Views: 774

Answers (3)

ant_Ti
ant_Ti

Reputation: 2425

All of jQuery mouse events not working with disabled input. But you can make overlay element located above input and bind events to him jsfiddle

Upvotes: 2

Matt
Matt

Reputation: 7249

To follow up on ant_Ti, while this is true that no events work. You can wrap it in a container: http://jsfiddle.net/zcHc4/4/

Upvotes: 0

genesis
genesis

Reputation: 50982

Probably none of them. That's meaning of "Disabled"

<input disabled="disabled" />
<script>

$("input").click(function(){
     alert("Clicked");
});
</script>

alert is not thrown

Upvotes: 1

Related Questions