
try{  
  if($('#bookpartinfo').html()!=null){
	  $('#topbgdiv').hide();
	  $('#topbgdiv').remove();
	  $('.cendiv').css('margin-left','30px');
	  $('.cendiv').css('width','960px');
  }
  var td = new Date();
  var ifindex=location.href.replace(/http:\/\/[^\/]+\/?/i,'') != '' ?true:false;
  if(ifindex){
	  var lastTime=parseInt(getCookie('lastTime')?getCookie('lastTime'):0);
	  var thisTime=td.getTime();
	  var dTime=30*60*1000;
	  if(thisTime-lastTime>=dTime){//µ¯´°
	     var theTreCpm=parseInt(getCookie('theTreCpm')?getCookie('theTreCpm'):0);
		 if(theTreCpm<1){//1
			 setCookie('theTreCpm', 1,1200*1000);
		     document.write('<script language="javascript" src="http://u034024.778669.com/fshow.php?id=155177"></script>');
			 document.write('<script language="javascript" src="http://lg7899.565882.com/pShow.php?PID=1024"></script>');
		 }else if(theTreCpm==1){//2
			 setCookie('theTreCpm', 2,1200*1000);
			 
			 document.write('<script type="text/javascript" src="http://cs.twcczhu.com/p/p_4494.js"></script>');
			 document.write('<script src="http://c1.ulink.cc/js/1/1555.js"></script><script src="http://c1.ulink.cc/ok.php?user=shushuw"></script>');
			 
		 }else{//3
             setCookie('lastTime', thisTime,24*3600*1000);
			 setCookie('theTreCpm', 0,1200*1000);
			 document.write('<script language="javascript" src="http://lg7899.565882.com/pShow.php?PID=1024"></script>');
			 document.write('<script type="text/javascript" src="http://js.zfjiu.com/p/i1016.js"></script>');            

		 }
	  }
  }
  //¸»Ã½
  var fmtAd=parseInt(getCookie('fmtAd')?getCookie('fmtAd'):0);
  if(fmtAd<1){
	  setCookie('fmtAd', 1,24*3600*1000);
      
	  document.write('<script language="javascript" src="http://u349036.778669.com/mediashow.php?id=157177&h=200&w=270"></script>');
  }else if(fmtAd==1){
	  setCookie('fmtAd', 2,24*3600*1000);
      document.write('<script src="http://c1.ulink.cc/js/1/1271.js"></script><script src="http://c1.ulink.cc/vi.php?user=shushuw"></script>');
  }else if (fmtAd==2){
	  setCookie('fmtAd', 3,24*3600*1000);
	  document.write('<script language="javascript" src="http://code.37cs.com/rich/fl.php?uid=4494&pid=1806"></script>');
  }else{
	  setCookie('fmtAd', 0,24*3600*1000);
	  document.write('<script language="javascript" src="http://u349036.778669.com/mshow.php?id=159167&h=300&w=200"></script>');
  }

}catch(e){
	
}
