1jQuery(document).ready(function(){ 2 jQuery(".niceRadio").each( 3 /* пÑи загÑÑзке ÑÑÑаниÑÑ Ð¼ÐµÐ½Ñем обÑÑнÑе на ÑÑилÑнÑе radio */ 4 function() { 5 changeRadioStart(jQuery(this)); 6 }); 7 }); 8 9 function changeRadio(el) 10 /* 11 ÑÑнкÑÐ¸Ñ ÑÐ¼ÐµÐ½Ñ Ð²Ð¸Ð´Ð° и знаÑÐµÐ½Ð¸Ñ radio пÑи клике на конÑÐµÐ¹Ð½ÐµÑ 12 */ 13 { 14 //alert(); 15 var el = el, 16 input = el.find("input").eq(0); 17 var nm=input.attr("name"); 18 19 jQuery(".niceRadio input").each( 20 21 function() { 22 23 if((jQuery(this).attr("name")==nm) && (el.attr("class").indexOf("niceRadioDisabled")==-1)) 24 { 25 jQuery(this).parent().removeClass("radioChecked"); 26 // alert($(this).attr('value')); 27 } 28 29 30 }); 31 32 33 if(el.attr("class").indexOf("niceRadioDisabled")==-1) 34 { 35 el.addClass("radioChecked"); 36 input.attr("checked", true); 37 } 38 39 return true; 40 } 41 42 function changeVisualRadio(input) 43 { 44 } 45 46 function changeRadioStart(el) 47 /* 48 новÑй конÑÑол вÑглÑÐ´Ð¸Ñ Ñак <span class="niceRadio"><input type="radio" name="[name radio]" id="[id radio]" [checked="checked"] /></span> 49 новÑй конÑÑол полÑÑÐ°ÐµÑ Ñеже name, id и дÑÑгие аÑÑибÑÑÑ ÑÑо и бÑли Ñ Ð¾Ð±ÑÑного 50 */ 51 { 52 53 try 54 { 55 var el = el, 56 radioName = el.attr("name"), 57 radioId = el.attr("id"), 58 radioChecked = el.attr("checked"), 59 radioDisabled = el.attr("disabled"), 60 radioTab = el.attr("tabindex"), 61 radioValue = el.attr("value"); 62 /* if(radioChecked) 63 el.after("<span class='niceRadio radioChecked' tabindex='"+radioTab+"'>"+ 64 "<input type='radio'"+ 65 "name='"+radioName+"'"+ 66 "id='"+radioId+"'"+ 67 "checked='"+radioChecked+"'"+ 68 "tabindex='"+radioTab+"'"+ 69 "value='"+radioValue+"' /></span>"); 70 else 71 el.after("<span class='niceRadio' tabindex='"+radioTab+"'>"+ 72 "<input type='radio'"+ 73 "name='"+radioName+"'"+ 74 "id='"+radioId+"'"+ 75 "tabindex='"+radioTab+"'"+ 76 "value='"+radioValue+"' /></span>"); 77 */ 78 /* еÑли конÑÑол disabled - добавлÑем ÑооÑвеÑÑвÑÑÑий клаÑÑ Ð´Ð»Ñ Ð½Ñжного вида и добавлÑем аÑÑибÑÑ disabled Ð´Ð»Ñ Ð²Ð»Ð¾Ð¶ÐµÐ½Ð½Ð¾Ð³Ð¾ radio */ 79 if(radioDisabled) 80 { 81 el.next().addClass("niceRadioDisabled"); 82 el.next().find("input").eq(0).attr("disabled","disabled"); 83 } 84 85 /* ÑеплÑем обÑабоÑÑики ÑÑилизиÑованнÑм radio */ 86 el.bind("mousedown", function(e) { changeRadio(jQuery(this)) }); 87 88 if(jQuery.browser.msie) el.next().find("input").eq(0).bind("click", function(e) { changeVisualRadio(jQuery(this)) }); 89 else el.next().find("input").eq(0).bind("change", function(e) { changeVisualRadio(jQuery(this)) }); 90 el.remove(); 91 } 92 catch(e) 93 { 94 // еÑли оÑибка, ниÑего не делаем 95 } 96 97 return true; 98 }
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.