1var votetype, rlogin = 0, voteobj, votea = ['citydxq', 'citydqg', 'cityxq', 'cityqg', 'travelstj', 'travelstj2', 'travels', 'travels2', 'visa']; 2var editor = new Array(); 3//æ·»å ç¼è¾å¨ 4function AddEditor(id, tool, RanNum) { 5 //$.include([webpath + 'sys/webedit/ueditor.config.js', webpath + 'sys/webedit/ueditor.all.js']); 6 var config = { 7 imageUrl: webpath + "sys/ajax/editorImageUp.ashx?r=" + RanNum, //å¾çä¸ä¼ å°å 8 imagePath: upfolder, //å¾çä¿®æ£å°åï¼å¼ç¨äºfixedImagePath,å¦æç¹æ®éæ±ï¼å¯èªè¡é ç½® 9 scrawlUrl: webpath + "sys/ajax/editorScrawlImgUp.ashx?r=" + RanNum, //æ¶é¸¦ä¸ä¼ å°å 10 scrawlPath: upfolder, //å¾çä¿®æ£å°åï¼åimagePath 11 catcherUrl: webpath + "sys/ajax/editorGetRemoteImage.ashx?r=" + RanNum, //å¤çè¿ç¨å¾çæåçå°å 12 catcherPath: upfolder, //å¾çä¿®æ£å°åï¼åimagePath 13 snapscreenHost: 'ueditor.baidu.com', //å±å¹æªå¾çserver端æä»¶æå¨çç½ç«å°åæè ipï¼è¯·ä¸è¦å http:// 14 snapscreenServerUrl: webpath + "sys/ajax/editorImageUp.ashx?r=" + RanNum, //å±å¹æªå¾çserver端ä¿åç¨åºï¼UEditorçèä¾ä»£ç 为âURL +"server/upload/net/snapImgUp.ashx"â 15 snapscreenPath: upfolder, 16 17 wordImageUrl: webpath + "sys/ajax/editorImageUp.ashx?r=" + RanNum, //word转åæäº¤å°å 18 wordImagePath: upfolder, // 19 getMovieUrl: webpath + "sys/ajax/editorGetMovie.ashx", //è§é¢æ°æ®è·åå°å 20 initialFrameWidth: '100%', 21 focus: false, 22 toolbars: [ 23 ['fullscreen', 'source', '|', 'undo', 'redo', '|', 24 'bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', '|', 25 'rowspacingtop', 'rowspacingbottom', 'lineheight', '|', 26 'customstyle', 'paragraph', 'fontfamily', 'fontsize', '|', 27 'directionalityltr', 'directionalityrtl', 'indent', '|', 28 'justifyleft', 'justifycenter', 'justifyright', 'justifyjustify', '|', 'touppercase', 'tolowercase', '|', 29 'link', 'unlink', 'anchor', '|', 'imagenone', 'imageleft', 'imageright', 'imagecenter', '|', 30 'insertimage', 'emotion', 'scrawl', 'insertvideo', 'music', 'attachment', 'insertframe', 'insertcode', 'webapp', 'pagebreak', 'template', 'background', '|', 31 'horizontal', 'date', 'time', 'spechars', 'snapscreen', 'wordimage', '|', 32 'inserttable', 'deletetable', 'insertparagraphbeforetable', 'insertrow', 'deleterow', 'insertcol', 'deletecol', 'mergecells', 'mergeright', 'mergedown', 'splittocells', 'splittorows', 'splittocols', '|', 33 'print', 'preview', 'searchreplace', 'help'] 34 ] 35 }; 36 if (!tool) tool = 'full'; 37 if (tool == 'simple') { 38 config.toolbars[0] = [ 'source', '|', 'undo', 'redo', '|', 39 'bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', '|', 40 'rowspacingtop', 'rowspacingbottom', 'lineheight']; 41 } else if (tool != 'full') { 42 config.toolbars[0] = $.map(config.toolbars[0], function (n) { 43 return n != 'pagebreak' ? n : null; 44 }); 45 } 46 editor[id] = UE.getEditor(id, config); 47} 48 49$(document).ready(function () { 50 mySearch(); 51 $('img[data-original]').lazyload({ threshold: 100 }); //å¾çå»¶æ¶å è½½ 52 $('.headSearch .sInput').focus(function () { //å¤´é¨æç´¢ 53 $('.headSearch .defaultKey').hide(); 54 }).blur(function () { 55 if (!$.trim($(this).val())) { 56 $('.headSearch .defaultKey').show(); 57 $(this).val(''); 58 } 59 });
60 $(".drop").hover(function () {//头é¨ä¸æ 61 $(this).find('.dropDown').show(); 62 $(this).addClass('hover'); 63 64 }, function () { 65 $(this).find('.dropDown').hide(); 66 $(this).removeClass('hover'); 67 }); 68 69 $('#loginout').click(function () { 70 $.get(webpath + 'sys/ajax/login.ashx', { act: "out" }, function () { 71 checklogin(); getvote(); 72 }); 73 }); 74 $('#login').click(function () { 75 rlogin = 2; 76 ShowWindow('', 'alertlogin', webpath + 'alertlogin.aspx'); 77 }); 78 $('#logins').click(function () { 79 rlogin = 2; 80 ShowWindow('', 'alertlogin', webpath + 'alertlogin.aspx'); 81 }); 82 checklogin(); 83 voteobj = $('[id^="citydxq_"],[id^="citydqg_"],[id^="cityxq_"],[id^="cityqg_"],[id^="travelstj_"],[id^="travels_"],[id^="travelstj2_"],[id^="travels2_"],[id^="visa_"]'); 84 if (voteobj.length > 0) { 85 voteobj.click(function () { 86 rlogin = 1; 87 var id = $(this).attr('id').split('_'); 88 if ($(this).attr('status') == 1) { 89 if (id[0] == 'visa') { 90 alert('æ¨å·²ç»æ¶èè¿!'); 91 } 92 return; 93 } 94 if ((id[0] != 'travelstj' && id[0] != 'travelstj2') && GetCookie('username') == '') { 95 votetype = $(this); 96 rlogin = 0; 97 ShowWindow('', 'alertlogin', webpath + 'alertlogin.aspx'); return; 98 } 99 favorites( 100 id[0], 101 id[1], 102 function () { 103 if (arguments[0] == 'true') { 104 if (id[0] == "citydxq" || id[0] == "citydqg") { 105 $('#' + id[0] + '_' + id[1]).removeClass('cur').addClass('cur'); 106 } else { 107 $('#' + id[0] + '_' + id[1]).removeClass('voteyes').addClass('voteno'); 108 } 109 $('#' + id[0] + 'text_' + id[1]).text((parseInt($('#' + id[0] + 'text_' + id[1]).text()) + 1)); 110 if (id[0] == 'visa') { 111 alert('æåæ¨æ¶èæå!'); 112 } 113 } 114 }); 115 }); 116 getvote(); 117 } 118}); 119 120//ä¼åä¸å¿å·¦ä¾§ 121$(".userNavTit1").click(function () { 122 if ($(this).find('div').hasClass("mores")) { 123 $(".curUNav").addClass("mores"); 124 $(".more").removeClass("curUNav"); 125 $(this).find('div').removeClass('mores').addClass("curUNav"); 126 } else { 127 if ($(this).find('div').hasClass("curUNav")) { 128 return; 129 } 130 131 $(this).find('div').addClass('mores'); 132 } 133 $('.userNavText').hide(); 134 $(this).next('.userNavText').slideToggle("slow"); 135}); 136 137 138//å¤´é¨æç´¢åæ¢ 139function mySearch() { 140 $('#optChange').hover( 141 function () { 142 $(this).find('dl').show(); 143 $(this).addClass('hover'); 144 }, 145 function () { 146 $(this).find('dl').hide(); 147 $(this).removeClass('hover'); 148 } 149 ); 150 151 $('#optChange dd').hover( 152 function () { $(this).addClass('cur'); }, 153 function () { $(this).removeClass('cur'); } 154 ).click( 155 function () { 156 $('.optionCur').html($(this).attr('text')); 157 $('#defaultKey').text($(this).attr('defaultkey')); 158 $('#optChange').removeClass('hover').find('dl').hide(); 159 $('#searchform').attr('action', $(this).attr('url')); 160 if (!$.trim($('#s_input').val())) { 161 $('#defaultKey').show(); 162 $('#s_input').val(''); 163 } 164 } 165 ).first().click(); 166} 167 168 169/*å¼¹åºç»éåè°*/ 170function AlertLoginReturn() { 171 checklogin(); 172 HideWindow(); 173 if (rlogin == 0) { 174 votetype.click(); 175 } else if (rlogin == 1) { 176 getvote(); 177 } 178} 179 180/*æ£æµç»é*/ 181function checklogin() { 182 if (GetCookie('username') == '') { 183 $('#logined').hide(); 184 $('#unlogin').show(); 185 } else { 186 $('#unlogin').hide(); 187 $('#logined_name').text(GetCookie('realname') == '' ? GetCookie('username') : GetCookie('realname')); 188 $('#logined').show(); 189 $.ajax({
190 type: "GET", 191 url: webpath + 'sys/Ajax/GetUserInfoCount.ashx', 192 cache: false, 193 dataType: "json", 194 success: function (json) { 195 if (json.CountSMS > 0) { 196 if ($(".sitemsg").length > 0) { 197 $('.sitemsg').html('ç«å ä¿¡:<a href="' + json.url + '" >æªè¯»(' + json.CountSMS + ')</a>'); 198 } else { 199 $('#logined').append('<span class="sitemsg">ç«å ä¿¡:<a href="' + json.url + '" >æªè¯»(' + json.CountSMS + ')</a></span>'); 200 } 201 } 202 } 203 }); 204 } 205} 206//æç¥¨ä¸æ¶è 207function getvote() { 208 if (voteobj.length == 0) return; 209 var url = webpath + 'sys/ajax/getvote.ashx?t=', adid = '', f, f1 = ''; 210 for (var i = 0; i < votea.length; i++) { 211 f = voteobj.filter('[id^="' + votea[i] + '_"]'); 212 if (f.length != 0) { 213 url += votea[i] + ','; 214 f1 += '&' + votea[i] + 'id='; 215 f.each(function () { 216 f1 += $(this).attr('id').replace(votea[i] + '_', '') + ','; 217 }); 218 f1 = f1.substring(0, f1.length - 1); 219 } 220 } 221 url = url.substring(0, url.length - 1) + f1 + '&callback=?'; 222 $.getJSON(url, 223 function (json) { 224 for (var i = 0; i < json.length; i++) { 225 for (var j = 0; j < json[i].item.length; j++) { 226 var t = json[i].item[j]; 227 $('#' + json[i].type + 'text_' + t.adid).text(t.votes); 228 $('#' + json[i].type + '_' + t.adid).attr('status', t.status); 229 if (t.status == 1) { 230 if (json[i].type == "citydxq" || json[i].type == "citydqg") { 231 $('#' + json[i].type + '_' + t.adid).addClass('cur'); 232 $('#' + json[i].type + 'text_' + t.adid).text(t.votes); 233 } else { 234 $('#' + json[i].type + '_' + t.adid).removeClass('voteyes').addClass('voteno'); 235 $('#' + json[i].type + 'text_' + t.adid).text(t.votes); 236 } 237 } else { 238 if (json[i].type == "citydxq" || json[i].type == "citydqg") { 239 $('#' + json[i].type + '_' + t.adid).removeClass('cur'); 240 $('#' + json[i].type + 'text_' + t.adid).text(t.votes); 241 242 243 } else { 244 $('#' + json[i].type + '_' + t.adid).removeClass('voteno').addClass('voteyes'); 245 246 $('#' + json[i].type + 'text_' + t.adid).text(t.votes); 247 } 248 } 249 } 250 } 251 $('[id^="cityxq_"]').each(function () { 252 var adid = $(this).attr('id').split('_')[1]; 253 if (parseInt($('#cityxqtext_' + adid).text()) + parseInt($('#cityxqtext_' + adid).text()) < 10) { 254 $('#cityvotelevel_' + adid).removeClass().addClass('s3'); 255 } 256 }); 257 } 258 ); 259};
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.