Because jquery is recently used, JS is written in the jquery format.
Code
1 <select name = "drpadaddress" id = "drpadaddress">
2 <option value = "0"> select </option>
3 <option value = "0" Disabled = "true"> homepage </option>
4 <option value = "4"> | --- homepage header </option>
5 <option value = "6" >|--- homepage left </option>
6 <option value = "7"> | --- Right of the homepage </option>
7 <option value = "0" Disabled = "true"> List page </option>
8 <option value = "9" >|--- left of the List </option>
9 <option value = "0" Disabled = "true"> news page </option>
10 <option value = "0" Disabled = "true"> Print the product page </option>
11 <option value = "19" >|--- printing </option>
12 <option value = "20" >|--- print header </option>
13 <option value = "0" Disabled = "true"> consumables page </option>
14 <option value = "22"> | --- ad on the consumables page </option>
15 <option value = "23"> | --- ad list on the consumables page </option>
16
17 </SELECT>
18
19
20 <SCRIPT type = "text/JavaScript">
21 $ (document). Ready (function (){
22 window. cache = 0;
23 $ ('# drpadaddress'). BIND ('change', function (e ){
24 var opt = $ ('# drpadaddress option: selected ');
25 if (OPT. ATTR ('Disabled ')){
26 This. value = Window. cache;
27} else {
28 window. cache = This. value;
29}
30 });
31 $ ('# drpadaddress option?disabled='0000.css ('color', 'graytext ');
32
33
34 })
35
36 </SCRIPT>