the read only property is not able to disable using jquery -
this question has answer here:
- disable/enable input jquery? 8 answers
in jquery
according condition make 1 field read below code
$("#name").attr("readonly", true);
it working fine
but when try disable using below codes
$("#name").attr("readonly", false); or $("#name").attr("disabled", false);
it not getting disabled. how can achieve it
the value of disabled attribute not matter. if in attribute list, element disabled regardless of whether false
or true
or empty. need remove attribute enable back.
use $("#name").removeattr('disabled')
re-enable element.
Comments
Post a Comment