var classid = rewinjson.tool.CheckParam(request.QueryString('classid'),'0'); //alert("classid = "+classid); var currentstr = window.location.href+""+"&f="+Math.random(); //类型转换 try{ currentstr = currentstr.substring(currentstr.search("\\\?")+1,currentstr.length); }catch(e){ currentstr = ""; } //调用公共Top信息 if(document.getElementById("public_top")){ new rewinjson.rewinAjax("/gkzq/public/top.jsp", new rewinjson.tool.parameter("style","","",""), function (repText,divID){ if(repText != null && repText.length>0){ repText = repText.trim();//去掉二头空格 repText = repText.replaceAll("\r\n",""); divID.innerHTML = repText; } }, "GET", "public_top" ); } //当执行完上面方法后开始执行下面的方法调用页头数据 //rewinjson.client.getTopData(rewinjson.client.TopInfoText); //调用公共的Left信息 if(document.getElementById("public_left")){ new rewinjson.rewinAjax("public/left.jsp", new rewinjson.tool.parameter("style","classid="+classid,"",""), function (repText,divID,aa){ if(repText!=null&&repText.length>0){ repText = repText.trim(); repText = repText.replaceAll("\r\n",""); divID.innerHTML = repText; } }, "GET", "public_left" ); } //当执行完上面方法后开始执行下面的方法调用左侧导航数据 //rewinjson.client.getLeftData(rewinjson.client.leftInfoText,classid); //调用公共Bottom信息 if(document.getElementById("public_bottom")){ new rewinjson.rewinAjax("/gkzq/public/bottom.jsp", new rewinjson.tool.parameter("style","","",""), function (repText,divID){ repText = repText.trim(); repText = repText.replaceAll("\r\n",""); divID.innerHTML = repText; }, "GET", "public_bottom" ); } //当执行完上面方法后开始执行下面的方法调用页脚数据 //rewinjson.client.getBottomData(rewinjson.client.BottomInfoText); //调用公共Foot信息 if(document.getElementById("public_foot")){ new rewinjson.rewinAjax("/gkzq/public/foot.jsp", new rewinjson.tool.parameter("style","","",""), function (repText,divID){ if(repText != null && repText.length>0){ repText = repText.trim();//去掉二头空格 repText = repText.replaceAll("\r\n",""); divID.innerHTML = repText; } }, "GET", "public_foot" ); } function logout(){ loginActionUrl="user/loginAction.jsp"; $.getJSON(loginActionUrl,{action:"logoff",ff:Math.round(Math.random()*10000)}, function(responseArray){ if(responseArray.success==true){ location.href="index.jsp"; }else{ alert('信息',responseArray.msg); } }); } var requests = { QueryString : function(val){ var uri = window.location.search; var re = new RegExp("" +val+ "=([^&?]*)", "ig"); return ((uri.match(re))?(uri.match(re)[0].substr(val.length+1)):null); } } var reps = requests.QueryString("reps"); function wopen(url){ var rep = document.location.href; window.open(url+"?reps="+rep); } function getnew_pagess(url,rep){ //window.open(url+"?reps="+rep); if(url.indexOf("?")!=-1){ window.location.href=url+"&reps="+rep; }else{ window.location.href=url+"?&reps="+rep; } } //退出网上营业厅 function logouts(rep){ loginActionUrl="user/loginAction.jsp"; //loginActionUrl=window.location.href; $.ajax({ type: "POST", url: loginActionUrl, data: "action=logoff", dataType:"json", success: function(responseArray){ if(responseArray.success==true){ //location.href="/xnzq/index.jsp"; //window.opener.location.reload(true); //alert(rep); //history.go(0); if(window.opener.closed&&(rep.indexOf("http")!=-1)&&rep!="1"){//判断父级窗口是否已经关闭 //window.open(rep);//已关 }else{//未关 try{ window.opener.location.href='/';} catch(err){ } } window.close(); window.opener.location=window.opener.location.href; }else{ alert('信息',responseArray.msg); } } }); } function CreateScript(url){ var new_element; new_element=document.createElement("script"); new_element.setAttribute("type","text/javascript"); new_element.setAttribute("src",url); document.body.appendChild(new_element); } //调用首页广告 if(document.getElementById("rewin_top")) { var t = n =count =0; new rewinjson.rewinAjax("/xnzq/v1.2/public/top.jsp", new rewinjson.tool.parameter("style","ff="+Math.random(),"",""), function (repText,divID){ if(repText != null && repText.length > 0){ repText = repText.trim();//去掉二头空格 repText = repText.replaceAll("\r\n",""); divID.innerHTML = repText; $(function(){ count = $("#playShow a").size(); showAuto=function() { n = n >= (count - 1) ? 0 : n+1; $("#playNum a").eq(n).trigger('click'); } $("#playShow a:not(:first-child)").hide(); $("#playText").html($("#playShow a:first-child").find("img").attr('alt')); $("#playNum a:first").css({"background":"#FF7027",'color':'#A8471C'}); $("#playText").click(function(){window.open($("#playShow a:first-child").attr('href'), "_blank")}); $("#playNum a").click(function() { var i = $(this).text() - 1; n = i; if (i >= count) return; $("#playText").html($("#playShow a").eq(i).find("img").attr('alt')); $("#playText").unbind().click(function(){window.open($("#playShow a").eq(i).attr('href'), "_blank")}) $("#playShow a").filter(":visible").hide().parent().children().eq(i).fadeIn(1200); $(this).css({"background":"#FF7027",'color':'#A8471C'}).siblings().css({"background":"#8a836a",'color':'#000'}); }); t = setInterval(showAuto,3000); $("#play").hover(function(){clearInterval(t)}, function(){t = setInterval(showAuto, 3000);}); }) } }, "GET", "rewin_top" ); } function gotoLinks(){ var url = document.getElementById("links").value; if(url != ""){ window.open(url); } } //加载头部-左侧-底部内容 function loadCommonInfo(){ //当执行完上面方法后开始执行下面的方法调用页头数据 rewinjson.client.getTopData(rewinjson.client.TopInfoText); //在此处加载左侧内容,如果在public.js加载会出现无法加载 rewinjson.client.getLeftData(rewinjson.client.leftInfoText,classid); //当执行完上面方法后开始执行下面的方法调用页脚数据 rewinjson.client.getBottomData(rewinjson.client.BottomInfoText); } //延迟加载(1000毫秒)头部-左侧-底部 信息 //setTimeout(loadCommonInfo,1000);