var zbp = new ZBP({ bloghost: "/blog/", blogversion: "173060", ajaxurl: "/blog/zb_system/cmd.php?act=ajax&src=", cookiepath: "/blog/", comment: { useDefaultEvents: false, inputs: { } } });var bloghost = zbp.options.bloghost; var cookiespath = zbp.options.cookiepath; var ajaxurl = zbp.options.ajaxurl;//********************************************************* // 目的: 全選 // 輸入: 無 // 返回: 無 //********************************************************* function BatchSelectAll() { $("input[name='id[]']").click(); } //********************************************************* //********************************************************* // 目的: // 輸入: 無 // 返回: 無 //********************************************************* function BatchDeleteAll(objEdit) { objEdit=document.getElementById(objEdit); objEdit.value=""; var aryChecks = document.getElementsByTagName("input"); for (var i = 0; i < aryChecks.length; i++){ if((aryChecks[i].type=="checkbox")&&(aryChecks[i].id.indexOf("edt")!==-1)){ if(aryChecks[i].checked){ objEdit.value=aryChecks[i].value+","+objEdit.value; } } }} //********************************************************* //********************************************************* // 目的: ActiveLeftMenu // 輸入: 無 // 返回: 無 //********************************************************* function ActiveLeftMenu(name){ name="#"+name; $("#leftmenu li").removeClass("on"); $(name).parent().addClass("on"); var s=$(name).children("span").css("background-image"); if(s!==undefined){ s=s.replace("1.png","2.png"); s=s.replace("1.svg","2.svg"); s=s.replace("1.gif","2.gif"); $(name).children("span").css("background-image",s); }} //********************************************************* //********************************************************* // 目(mù)的(de): ActiveTopMenu // 輸入(rù): 無 // 返回: 無 //********************************************************* function ActiveTopMenu(name){ name="#"+name; $("#topmenu li").removeClass("on"); $(name).addClass("on");} //*********************************************************//********************************************************* // 目的: 表格(gé)斑馬線 // 輸入: 無 // 返回: 無 //********************************************************* function bmx2table(){ }; //********************************************************* //********************************************************* // 目的: CheckBox // 輸入: 無 // 返回: 無 //********************************************************* function ChangeCheckValue(obj){ if ($(obj).hasClass("imgcheck-disabled")) { return; } $(obj).toggleClass('imgcheck-on'); if($(obj).hasClass('imgcheck-on')){ $(obj).prev('input').val('1'); $(obj).next('.off-hide').show(); }else{ $(obj).prev('input').val('0'); $(obj).next('.off-hide').hide(); }} //********************************************************* //********************************************************* // 目的: Notifications // 輸入: 無 // 返回: 無 //********************************************************* function notify(s){ if (window.webkitNotifications) { if (window.webkitNotifications.checkPermission() == 0) { var zb_notifications = window.webkitNotifications.createNotification('/blog/zb_system/image/admin/logo-16.png', '通知', s); zb_notifications.show(); zb_notifications.onclick = function() {top.focus(),this.cancel();} zb_notifications.replaceId = 'Meteoric'; setTimeout(function(){zb_notifications.cancel()},5000); } else { window.webkitNotifications.requestPermission(notify); } } } //*********************************************************function statistic(s){ $("#statistic i").addClass("loading-status"); $("#updatatime").hide(); $.ajax({ type: "GET", url: s+"&tm="+Math.random(), data: {}, error: function(xhr, exception){ if( xhr.status == "500") { alert('清空緩存並重新編譯模板\n\r操作失敗'); } setTimeout(function () { $("#statistic i").removeClass("loading-status"); }, 500); $("#updatatime").show(); }, success: function(data){ $("#tbStatistic tr:first ~ tr").remove(); $("#tbStatistic tr:first").after(data); setTimeout(function () { $("#statistic i").removeClass("loading-status"); }, 500); $("#updatatime").show(); } });}function updateinfo(s){ $("#tbUpdateInfo i").addClass("loading-status"); $.get(s+"&tm="+Math.random(),{}, function(data){ $("#tbUpdateInfo tr:first ~ tr").remove(); $("#tbUpdateInfo tr:first").after(data); setTimeout(function () { $("#tbUpdateInfo i").removeClass("loading-status"); }, 500); } ); } function AddHeaderIcon(s){ var element = $("div.divHeader,div.divHeader2").first(); element.css({"background-image":"url('"+s+"')"}); element.html(''+element.text()+''); }function AddHeaderFontIcon(icon_class){ var element = $("div.divHeader,div.divHeader2").first(); element.css("background-image", "url(\"" + zbp.options.bloghost + "zb_system/image/admin/none.gif\")"); var text = element.text(); element.html(' '+text+''); } function AutoHideTips(){ $("p.hint:visible").each(function(i){ if ( !$(this).hasClass("hint_always") ){ $(this).delay($(this).attr("data-delay")).hide(1500,function(){}); } }); }function ShowCSRFHint() { $('.main').prepend('
您在此頁麵(miàn)已停留 %s 小時,可能需要刷新頁麵後才能正常使用各功能。