function hfmove(){ this.sbtn = $(".show-btn"); this.popfooter = $(".pop-footer"); this.wrap = $("#wrap"); this.cover = $(".popup-cover"); this.flist = $(".lists h5"); this.weixi = $(".weixinico"); this.mobilebar = $('.mobilebar'); this.scrolltop=0; this.open = false; this.pbtn = $("[data-pop]"); this.pcover = $(".p-cover"); this.pclose = $(".popup-close"); this.aa = $(".comtoolpoptitle .close"); this.bb = $(".popup-success .sclose"); this.cc = $(".popup-xb .sclose"); if(ishandle.lowerie8())this.browser(); else this.init(); }; hfmove.prototype = { browser:function (){ var warninghtml ='

浣犵殑娴忚鍣ㄧ増鏈お鏃э紝鐐瑰嚮涓嬭浇鏈€鏂扮増鏈?/h3>
  • firefox
  • chrome
  • opera
  • safari
  • ie10
  • ie9

娴忚鍣║a淇℃伅锛歁ozilla/4.0锛坈ompatible锛沵sie 7.0锛沇indows nt 6.1锛汼lcc2锛汵et clr 2.0.5727锛汵et clr 3.5.30729锛汵et4.0c锛汿ablet pc 2.0锛汢oie9锛沍hcn)

娴忚鍣ㄧ骇鍒細5锛堜笌ie5鐩稿綋锛?/p>

'; $('html,body').css("background","#fff"); $('body').html(warninghtml); }, init:function(q){ var self=this; if(!q){ this.run(); } this.menulinemove(); settimeout(function(){ self.slidebar();},100); $('.newspage').size() > 0 && this.pagecenter(); if (ishandle.any() && !ishandle.ipad() && $("#afooter24hour") != null) { $("#afooter24hour").attr("href", "tel:4009773030"); //$("#afooterasktel").attr("href", "tel:073188198888"); } }, menulinemove:function(){ var self = this; $('.menubox > li').click(function(){ var index = $(this).index(); var _w = $(this).width(); _left= index==7?90*index+30:90*index; if(!$(this).attr('class')){ // $('.redline').stop().animate({ // left:_left, // width:_w, // },500); $(this).siblings().removeclass('on'); $(this).addclass('on'); self.wrap.addclass('opennav'); }else{ $(this).removeclass('click'); $(this).removeclass('on'); self.wrap.removeclass('opennav'); } }); }, resets: function(){ var self = this; if(ishandle.any() && !ishandle.ipad()){ var _hh = $(window).height() * 2; self.popfooter.css("transform","translate(0,"+_hh+"px)"); // self.popfooter.hide(); } }, dropdown:function(){ var self = this; $('.menubox > li').bind('mouseover',function(){ //$(this).siblings().removeclass('on') $(this).addclass('on'); self.wrap.addclass('opennav'); }); $('.menubox > li').bind('mouseleave', function () { $(this).removeclass('on'); self.wrap.removeclass('opennav'); }); }, run: function(){ var self = this; this.resets(); if (!ishandle.any()) { this.dropdown(); } else { $(".menu .headmenu ul.menubox li").each(function (index, element) { var menulink = $(this).find("a").eq(0); if ($(menulink).attr("href").tolowercase().indexof("promotions") > 0 && $(menulink).attr("href").tolowercase().indexof("?") == -1) { $(menulink).attr("href", "javascript:;"); } }); } this.sbtn.bind("click",function(){ self.wrap.removeclass(); if(!self.open){ self.openfooter(); $('.wrapper').css('height',$(window).height()); $('.wrapper').css('overflow-y','hidden'); // $('body,html').css('overflow-y','hidden'); }else{ self.closefooter(); $('.wrapper').removeattr('style'); // $('.fram').css('overflow-y','auto'); // $('body,html').css('overflow-y','auto'); } }) this.cover.bind("click",function(){ if(self.open){ self.closefooter(); $('.wrapper').removeattr('style'); } }) this.flist.bind("click",function(){ if(self.open){ $(this).parent().toggleclass("on").siblings().removeclass("on"); } }) this.weixi.bind("mouseover",function(){ $(this).find('.weixin').show(); }) this.weixi.bind("mouseleave",function(){ $(this).find('.weixin').hide(); }) // wt(".inputplaceholder").placeholder(); wt(".inputcenter").inputcenter(); wt(".imageslist").imageslistspeed(); wt(".selectinfo").select(); wt(".videoinfo").video(); // 璐溅宸ュ叿 this.pbtn.on("click",function(){ self.popopen($(this)); }); this.pcover.on("click",function(){ self.coverclose($(this)); }); this.pclose.on("click",function(){ self.popclose($(this)); }); this.aa.on("click",function(){ self.closeajaxpop(); }); this.bb.on("click",function(){ self.closesuccess(); }); this.cc.on("click",function(){ self.closexb(); }); }, showtool:function(){ var self=this; $("[data-pop]").bind("click",function(){ self.popopen($(this)); }); }, openfooter: function(){ var self = this; this.wrap.addclass("openfooter"); this.cover.fadein(300,function(){ self.open = true; }) if(ishandle.isie8() || ishandle.isie9()){ this.popfooter.animate({"bottom":0},300); } }, closefooter: function(){ var self = this; this.wrap.removeclass("openfooter"); this.cover.fadeout(300,function(){ self.open = false; }) if(ishandle.isie8() || ishandle.isie9()){ // debugger this.popfooter.animate({"bottom":-254},300); } }, slidebar:function(){ var self = this; if(ishandle.any() && !ishandle.ipad()){ var _h = $(window).height(); $('.dheader .menu').css('height',_h); $('.dheader .menu .menubox').css('height',_h-245); this.mobilebar.bind('click',function(){ if( $(this).children('a').hasclass('click')){ $(this).children('a').removeclass('click'); self.wrap.removeclass('opensildebar'); tweenmax.to($("#wrap .dheader").get(0),.2,{css:{left:0}}); tweenmax.to($("#wrap .fram").get(0),.2,{css:{left:0}}); tweenmax.to($("#wrap .footer").get(0),.2,{css:{left:0}}); self.wrap.removeclass('opennav'); $('.popup-cover').hide(); $("body,html").removeattr('style').css("display","block"); $(window).scrolltop(self.scrolltop); }else{ $(this).children('a').addclass('click'); self.wrap.addclass('opensildebar'); tweenmax.to($("#wrap .dheader").get(0),.2,{css:{left:-240}}); tweenmax.to($("#wrap .fram").get(0),.2,{css:{left:-240}}); tweenmax.to($("#wrap .footer").get(0),.2,{css:{left:-240}}); //#wrap.opensildebar .dheader $('.popup-cover').show(); self.scrolltop=$(window).scrolltop(); $("body,html").css({"overflow":"hidden","width":"100%","height":"100%"}); } }); $('.dheader .menu li').bind('click',function(){ // $(this).siblings().removeclass('click'); //$(this).addclass('click'); }); $('.popup-cover').bind('click',function(){ if($(this).is(':visible')){ tweenmax.to($("#wrap .dheader").get(0),.2,{css:{left:0}}); tweenmax.to($("#wrap .fram").get(0),.2,{css:{left:0}}); tweenmax.to($("#wrap .footer").get(0),.2,{css:{left:0}}); self.wrap.removeclass('opensildebar'); self.wrap.removeclass('opennav'); self.mobilebar.children('a').removeclass('click'); $('.popup-cover').hide(); $("body,html").removeattr('style').css("display","block"); $(window).scrolltop(self.scrolltop); } }) } if(ishandle.any()){ $(window).bind("touchstart",function(e){ if(!$(e.target).is("input")&&!$(e.target).is("textarea")){ $("input").trigger("blur"); $("textarea").trigger("blur"); } }) } }, pagecenter:function(){ var size = $('.newspage li').size(); var _w = 40*size; $('.newspage').css('width',_w); }, popopen:function(obj){ //console.log(obj.get(0)) var self = this; var tar = obj.data("pop"); var ctrl = obj.data("ctrl"); // $("body,html").css({"overflow":"hidden"}); this.scrolltop=$(window).scrolltop(); if(ishandle.any()){ $("body,html").css({"overflow":"hidden","width":"100%","height":"100%"}); }else{ $("body,html").css({"overflow":"hidden"}); } switch(ctrl){ case 1: window.parent.$(".popup-"+ tar).fadein(); this.pcover.fadein(); break; case 2: var htmls = obj.data("html"); var tow = obj.data("tow") || ""; var sin = obj.data("single") || 0; var nhtmls = htmls + "?tow=" + tow; var iframe = ''; var ld = $(".popup-"+ tar + " .laodingbox"); ld.fadein(); if($("#ajaxi").size()>0){ $("#ajaxi").get(0).src=nhtmls; $("#ajaxi").attr("data-sin",sin) }else{ $(".popup-"+ tar).append($(iframe));} $("#ajaxi").load(function(){ ld.hide(); $("#ajaxi").fadein(); // $(window.frames["ajaxxx"].document).find(".close").css("display","block"); // $(window.frames["ajaxxx"].document).find("#horiprompt").remove(); }) $(".popup-"+ tar).fadein(); break; case 3: var maps = obj.data("maps"); var pinyin = $("#hid_dealerpinyin").val(); var iframe = ''; var ld = window.parent.$(".popup-"+ tar + " .laodingbox") if(!window.parent.$("#ajaxmap").size()>0){ ld.fadein(); window.parent.$(".popup-"+ tar).append($(iframe)); }else{ window.parent.$("#ajaxmap").attr("src", "/"+pinyin+"/buytools/buychooses/dealersearch?" + maps); } window.parent.$("#ajaxmap").load(function(){ ld.hide(); window.parent.$("#ajaxmap").fadein(); // $(window.parent.window.frames['ajaxmmm'].document).find(".close").css("display","block"); // $(window.parent.window.frames['ajaxmmm'].document).find("#horiprompt").remove(); }) window.parent.$(".popup-"+ tar).fadein(); break; } }, opensuccess:function(){ window.parent.$(".popup-success").fadein(); }, carcomp:function(obj){ var comp = obj.data("comp"); var iframe = ''; var ld = window.parent.$(".popup-comp .laodingbox"); if(!window.parent.$("#ajaxii").size()>0){ ld.fadein(); window.parent.$(".popup-comp").append($(iframe)); }else{ window.parent.$("#ajaxii").attr("src","toolpage/toolcompareresult.html?"+ comp); } window.parent.$("#ajaxii").load(function(){ ld.hide(); window.parent.$("#ajaxii").fadein(); // $(window.parent.window.frames['ajaxccc'].document).find(".close").css("display","block"); // $(window.parent.window.frames['ajaxccc'].document).find("#horiprompt").remove(); }) window.parent.$(".popup-comp").fadein(); }, popclose: function(obj){ obj.parents(".popup-box").fadeout(); this.pcover.fadeout(); $("body,html").removeattr('style').css("display","block"); $(window).scrolltop(this.scrolltop); }, coverclose: function(obj){ $(".popup-box:visible").fadeout(); obj.fadeout(); $("body,html").removeattr('style').css("display","block"); $(window).scrolltop(this.scrolltop); }, closeajaxpop:function(){ if(parseint(window.parent.$("#ajaxi").attr("data-sin"))){ $(window).scrolltop(this.scrolltop); } if(window.parent.$(".popup-maps").is(":visible")){ window.parent.$(".popup-maps").fadeout(400); window.parent.$("#ajaxmap").remove(); }else if(window.parent.$(".popup-comp").is(":visible")){ window.parent.$(".popup-comp").fadeout(400); }else{ window.parent.$(".popup-ajax").fadeout(400); } window.parent.$("body,html").removeattr('style').css("display","block"); }, closesuccess:function(){ $(".popup-success").fadeout(400); }, openxb:function(){ //$("body,html").css({"overflow-y":"hidden"}); $(".popup-xb").fadein(); }, closexb:function(){ // $("body,html").removeattr('style'); $(".popup-xb").fadeout(400); } }; // new hfmove(); var menumove = null; if(!menumove){ menumove = new hfmove(); }else{ menumove.init(); } $("#adlogout").click(function () { $.ajax({ type: "post", url: "/ajax/commonhandler.ashx?method=logout", contenttype: "application/json; charset=utf-8", datatype: "json", async: false, success: function (data) { if (data.result == "1") { location.reload(); } else { window.alert("閫€鍑哄け璐?); } } }); });