driver.find_element_by_id('idname').clear()
driver.execute_script('document.getElementById("idname").removeAttribute("readOnly");')
driver.find_element_by_id('idname').clear()
driver.execute_script('document.getElementById("idname").removeAttribute("readOnly");')
转载于:https://www.cnblogs.com/chxtdbk/p/9828981.html