$(”#ID“).attr("readonly","readonly");//只读
$(”#ID“).removeAttr("readonly");//可写应该是这么写的、