This article mainly introduces how to click the check box in javascript to change the button or text box to gray and unavailable. It involves some tips on Dynamically modifying page element attributes in javascript and has reference value, you can refer to the example in this article to show how to click the check box in JS to change the button or text box to gray unavailable. Share it with you for your reference. The details are as follows:
It is often invisible during registration. If you do not click to read the Registration License, the submit button is gray and cannot be submitted if it is invalid. You must click it. This JS code is used to implement this function, the button below takes effect only when you click confirm to submit.
Shows the running effect:
The Code is as follows:
Click the check box button to change to unavailableScript var checkobjfunction agreesubmit (el) {checkobj = elif (document. all | document. getElementById) {for (I = 0; I
Script document. forms. agreeform. agreecheck. checked = false script
I hope this article will help you design javascript programs.