﻿
var aF = new Array();
aF[0] = "progid:DXImageTransform.Microsoft.Barn(function=30, duration=1)";
aF[1] = "progid:DXImageTransform.Microsoft.Blinds(direction='down', duration=1)";
aF[2] = "progid:dximagetransform.microsoft.wipe(gradientsize=1.0,wipestyle=4, motion=forward, duration=2)";
aF[3] = "progid:DXImageTransform.Microsoft.CheckerBoard(duration=1, direction='left')";
aF[4] = "progid:DXImageTransform.Microsoft.Iris(duration=1)";
aF[5] = "progid:DXImageTransform.Microsoft.Slide(bands=20, duration=1)";
aF[6] = "progid:DXImageTransform.Microsoft.Spiral(duration=1, GridSizeX=25, GridSizeY=25)"; 
aF[7] = "progid:DXImageTransform.Microsoft.Strips(duration=1)";
aF[8] = "progid:DXImageTransform.Microsoft.Wheel(duration=1,spokes=10)";
aF[9] = "progid:DXImageTransform.Microsoft.Zigzag(duration=1, GridSizeX=25, GridSizeY=25)"; 
aF[10] = "progid:DXImageTransform.Microsoft.Fade(duration=1)";

document.write('<style>');
document.write('.axx{padding:2px 3px; margin:2px;border-left:#cccccc 1px solid;font:12px}');
document.write('a.axx:link,a.axx:visited{text-decoration:none;color:#fff;line-height:12px;font:12px sans-serif;background-color:#1B2E40;}');
document.write('a.axx:active,a.axx:hover{text-decoration:none;color:#fff;line-height:12px;font:12px sans-serif;background-color:#1B2E40;}');
document.write('.bxx{padding:2px 3px;border-left:#cccccc 1px solid;font:12px}');
document.write('a.bxx:link,a.bxx:visited{text-decoration:none;color:#fff;line-height:12px;font:12px sans-serif;background-color:#D73240;}');
document.write('a.bxx:active,a.bxx:hover{text-decoration:none;color:#fff;line-height:12px;font:12px sans-serif;background-color:#D73240;}');
document.write('</style>');
var GO = function(elemId){
		if(document.getElementById){
			return document.getElementById(elemId);
		}else if(document.layers){
			document.layers[elemId];
		}else{
			return eval('document.all.' + elemId);
		}
	}
	//GO("wdivname_2").className='wdiv_n';
	
	
	function CheckAll(tcheck)
  {
  var e=document.getElementsByName("id");
  for (var i=0;i<e.length;i++)
    {
   
   
       e[i].checked = tcheck;
    }
  }
	
	
		function tongpr(obj)
	{
	//alert(obj.scrollLeft);
	  if(GO(obj))
	  {
	  
	   //alert(GO(obj))
	  if(GO(obj).scrollLeft>0)
	   GO(obj).scrollLeft=parseInt(GO(obj).scrollLeft)-180;
	  }
	}
	
	function tongnext(obj)
	{
	 if(GO(obj))
	  {
	  
	   GO(obj).scrollLeft=parseInt(GO(obj).scrollLeft)+180;
	  // alert(parseInt(obj.scrollLeft))
	  }
	}
	
	
	var indexi=1,indexchage=true;
	
	//主页轮换
	function indexchangereturn()
	{
	  if(indexchage)
	  {
	   if(GO("d_"+indexi))
	   {
	     titlechange('d',indexi);
	     indexi++;
	     if(indexi>3)indexi=1;
	     setTimeout('indexchangereturn()',2000);
	   }
	 }
	}
	
	setTimeout('csh()',100);
	//window.onload=csh;
	function csh()
	{
		//alert("tempstr")
		if(GO("showclass"))
		{
			var tempstr=GO("showclass").value;
			
			//titlechange(tempstr);
			if(GO(tempstr))
GO(tempstr).style.display="block";

		}
		
		if(GO("centerimg"))
		{
		   trychange(1);
		}
		if(GO("d_"+indexi))
		{
		  setTimeout('indexchangereturn()',1000);
		}
	}

	function madieremove()
	{
	 if(GO("madieshow"))
  {
	  var p;
        if(p =GO("madieshow").parentNode)   
        {   
         p.removeChild(GO("madieshow"));   
        }
        }   
	}
	function titlechange(tname,tnum)
	{
		for(var i=1;i<5;i++)
		{
		  if(!GO(tname+"_"+i))break;
	
		  GO(tname+"_"+i+"_1").style.display='none';
		  GO(tname+"_"+i).style.background="";
		  
		}
		if(GO(tname+"_"+tnum))
		{
		
			 GO(tname+"_"+tnum+"_1").style.display='block';
		
			 GO(tname+"_"+tnum).style.background="url('images/indext1.jpg')";
			 
			   GO(tname+"_"+tnum).style.backgroundRepeat="no-repeat";
			// .style.background="url('img/a.jpg')";
		}
	}
	
	
	
		function trychange(obj)
	{
	
	//this.style.border='3px solid #FFCB65';
		for(var i=1;i<4;i++)
		{
		  if(!GO("trydian_"+i))break;
		 
		  GO("trydian_"+i).style.border='';
		  GO("trydian_"+i+"_1").style.display='none';
		 
		  
		}
		if(GO("trydian_"+obj))
		{
		
		 GO("trydian_"+obj).style.border='3px solid #FFCB65';
		  GO("trydian_"+obj+"_1").style.display='block';
			 
		}
		
	}
	
	
	
	
function viptrychange(obj)
	{
	
	//this.style.border='3px solid #FFCB65';
		for(var i=1;i<4;i++)
		{
		  if(!GO("v_"+i))break;
		 
		  GO("v_"+i).style.color='#666666';
		  GO("v_"+i+"_1").style.display='none';
		 
		  
		}
		if(GO("v_"+obj))
		{
		
		 GO("v_"+obj).style.color='#FF6600';
		  GO("v_"+obj+"_1").style.display='block';
			 
		}
		
	}
	
	
	
	function classchange(obj)
	{
	if(GO("pclassshow_"+obj))
		{
	if( GO("pclassshow_"+obj).style.display=='block')
	{
	 GO("pclassshow_"+obj).style.display='none';
		}
	else
	{
	 GO("pclassshow_"+obj).style.display='block';
	}
	}
	
	
	
//		for(var i=1;i<=3;i++)
//		{
//		  if(!GO("pclassshow_"+i))break;

//		  GO("pclassshow_"+i).style.display='none';
//		 
//		  
//		}
//		if(GO("pclassshow_"+obj))
//		{
//		
//		
//		  GO("pclassshow_"+obj).style.display='block';
//			 // GO("ad_"+obj+"_inner").style.display='none';
//		}
		//alert(GO("ad_1").src)
	}
	
	
	function c_show(obj)
	{
	if(GO(obj))
		{
	if( GO(obj).style.display=='block')
	{
	 GO(obj).style.display='none';
		}
	else
	{
	 GO(obj).style.display='block';
	}
	}
	}
	function adchange1(obj)
	{
	
	
	if(obj=='1')
	{
	   GO("ad_1").style.background="url('images/test02.jpg')";
	   GO("ad_1_1").style.display='block';
	   GO("ad_2").style.background="url('images/test.jpg')";
	   GO("ad_2_1").style.display='none';
	}
		else
		{
		  GO("ad_1").style.background="url('images/test0.jpg')";
	   GO("ad_1_1").style.display='none';
	   GO("ad_2").style.background="url('images/test1.jpg')";
	   GO("ad_2_1").style.display='block';
		}
		
		GO("ad_2").style.backgroundRepeat="no-repeat";
		//alert(GO("ad_1").src)
	}
	
	
	
	function helpshow(obj)
	{ //alert(obj);
		if(GO(obj))
		{
		 if(GO(obj).style.display=='none')
		 GO(obj).style.display='block';
		 else
		 GO(obj).style.display='none';
		}
	}

 function showing(imgid,twidth,theight)
    {
     var mypic = new Image();
     mypic.src = imgid.src;
     var mywidth = mypic.width;
     var myheight = mypic.height;
     if(mywidth>=myheight)
     {
       if (mywidth >= twidth)
      {    
       imgid.style.width = twidth;
       imgid.style.height = Math.floor(myheight/(mywidth/twidth));
      }
     }
     else
     {
       if (myheight >= theight)
        {    
         imgid.style.height = theight;
         imgid.style.width = Math.floor(mywidth/(myheight/theight));
        }
      }
    
    }
 
 
        function madieshow(twidth,theight,url)
	{
document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="'+twidth+'" height="'+theight+'">');
    document.write('<param name="movie" value="/Flvplayer.swf" />');
    document.write('<param name="quality" value="high" />')
// document.write('<param name="AUTOSTART" value="true" />')
document.write('<param name="menu" value="false" />')

    document.write('<param name="allowFullScreen" value="true" />')
    document.write('<param name="FlashVars" value="vcastr_file='+url+'&IsAutoPlay=1&IsContinue=1" />')
    document.write('<embed src="/Flvplayer.swf" allowfullscreen="true" flashvars="vcastr_file='+url+'&LogoText=www.yowbo.com" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+twidth+'" height="'+theight+'"></embed>')
 document.write('</object>')
}


function checkreg(tvalue,action)
{
   var turl='/ajaxcheck/regcheck.ashx?action='+action+'&tvalue='+escape(tvalue);
   ajax_function(turl,'re_'+action);
}

function re_checkuser(nn)
{
   if(nn!='')
   {
   // GO("buttonusername").disabled=false;
     if(nn=='1')
     {
      GO("divusername").innerHTML='<span class="noreged" >此用户可以注册</span>';
     }
     else
     {
     GO("divusername").innerHTML='<span class="isreged" >此用户己被注册</span>';
     }
   }
  else
   {
      GO("divusername").innerHTML='<span class="isreged" >此名称不能为空</span>';
   }
}

function re_checkblogname(nn)
{
   if(nn!='')
   {
  //  GO("buttonblogname").disabled=false;
     if(nn=='1')
     {
      GO("divblogname").innerHTML='<span class="noreged" >此名称可以注册</span>';
     }
     else
     {
     GO("divblogname").innerHTML='<span class="isreged" >此名称己被注册</span>';
     }
   }
   else
   {
      GO("divblogname").innerHTML='<span class="isreged" >此名称不能为空</span>';
   }
}


function re_checkpho(nn)
{
   if(nn!='')
   {
   // GO("buttonphoname").disabled=false;
     if(nn=='1')
     {
      GO("divphoname").innerHTML='<span class="noreged" >此手机号码可以注册</span>';
     }
     else
     {
     GO("divphoname").innerHTML='<span class="isreged" >此手机号码己被注册</span>';
     }
   }
   
    else
   {
      GO("divphoname").innerHTML='<span class="isreged" >手机号码不能为空</span>';
   }
}



	function allsearchchange(tname,tnum)
	{
		for(var i=1;i<=5;i++)
		{
		  if(!GO("div_s_"+i))break;
	
		//  GO("div_s_"+i).style.display='none';
		   GO("div_s_"+i).style.background='';
		   GO("div_s_"+i).className='STYLE7';
		  
		}
		if(GO("div_s_"+tnum))
		{
		
			// GO("div_s_"+tnum).style.display='block';
		  GO("div_s_"+tnum).className="STYLE5";
			GO("div_s_"+tnum).style.background="url('images/b5.gif')";
			 
			GO("div_s_"+tnum).style.backgroundRepeat="no-repeat";
			// .style.background="url('img/a.jpg')";
			GO("weballsearchlink").value=tname;
		}
	}
	
	
	function allsearchsub()
	{
	  if(GO("allsearchvalue"))
	  {
	    var tvalue=GO("allsearchvalue").value;
	    if(tvalue=='')
	    {
	     alert('搜索内容不能为空！');
	    }
	    else
	    {
	      var turl=GO("weballsearchlink").value+'?value='+escape(tvalue);
	      location.href=turl;
	    }
	  }
	}
	
	function allsearchchangered(tname,tnum)
	{
		for(var i=1;i<=5;i++)
		{
		  if(!GO("div_s_"+i))break;
	
		//  GO("div_s_"+i).style.display='none';
		   GO("div_s_"+i).style.background='';
		   GO("div_s_"+i).className='STYLE5';
		  
		}
		if(GO("div_s_"+tnum))
		{
		
			// GO("div_s_"+tnum).style.display='block';
		  GO("div_s_"+tnum).className="STYLE6";
			GO("div_s_"+tnum).style.background="url('/images/b1.gif')";
			 
			GO("div_s_"+tnum).style.backgroundRepeat="no-repeat";
			// .style.background="url('img/a.jpg')";
			GO("weballsearchlink").value=tname;
		}
	}