No stranger to the linkage menu, but this is the first time I wrote the linkage. The principle is very simple, but it is still a little difficult to achieve the goal: 1. Click "anonymous group" and automatically jump: "Private Group" and "Access Control" group members"
2. Click "public group" to automatically jump to: member type "real-name group"
The first is to obtain the click radio event. The jquery library is used to determine the radio after the event is obtained. Then, the radio is checked and then the linkage transformation is performed. The problems encountered are: the events compatible with ie and firefox, and then the selected Attribute of options in select.
Compatible with ie and firefox, var ie = document. all; var nn6 = document. getElementById &! is used &&! Document. all;
Set the selected Attribute of options in select to var t = document. getElementsByName ("select1") [0] [1]; t. setAttribute ("selected", "selected ");
When setting the selected Attribute, document. getElementsByName ("select1"). options is usually used, but firefox reports undefined. Then, an array is used to solve the problem.
The complete code for achieving objective 1 is as follows:
Html
The Code is as follows: