Add foreground control to the project radio, the operation of two div display and hide, is actually a very simple problem, but the cost of the boss to complete, that is, jquery operation control of some basic knowledge. There are three kinds of methods, briefly introduced:
1. Set the style property for the element:
$ ("#divShareExamPage"). attr ("style""display : none; " ); $ ("#divExamPage"). attr ("style" ) " Display:block; ");
2. Change the CSS style of the control via jquery:
$ ("#divShareExamPage"). CSS ("display""None" "); $ ("#divExamPage"). CSS ("display "block");
3, through the jquery own show (), Hide () method:
$ ("#divExamPage"). Show (); $ ("#divShareExamPage") . Hide ();
To manipulate the foreground control radio:
<TD align =" Right"> <input type="Radio"Id="radioteachercreate"Value ="Personal Test Paper"Name ="Exampage" checked="checked"onclick ="Clickradio ()"/>Personal Test Paper<input type="Radio"Id="Radioshare"Value ="Share Quiz"Name ="Exampage"onclick ="Clickradio ()"/>Share Quiz<input type="Radio"Id="Radiosystem"Value ="System Papers"Name ="Exampage"onclick ="Clickradio ()"/>System Papers</td>
Extract the value values in the radio:
var radiovalue = $ ("input[name= ' exampage ']:checked"). Val ();