I'm trying to make a button available only if the content of an input changed this way:
$(document).ready(function() {
$('input[name="tesztinput1"]').keyup(function(){
alert('Content has been changed');
if ($(this).val())
{
$('input[name="tesztinput3"]').removeAttr('disabled');
}
})
});
And in the HTML:
<input name="tesztinput1" type="text"/>
<input name="tesztinput3" type="button" disabled="disabled" value="Click"/>
It properly works if the element which i want to remove disable attribute is a text input aswell but not working on buttons and submit elements. Any idea?
So this part of the code itself seems to be okay I tested every suggestion in the recent answer and no result. What else could block me from executing an action like this?