I have this function toggles the disabled attribute form a input field:
$(\'.someElement\').click(function(){ if (someCondition) { console.log($
$("#vp_code").textinput("enable"); $("#vp_code").textinput("disable");
you can try it