function top_bgt(bgt){	
if(bgt==0){
    $("#bgt_submeun").show();
}else{
	$("#bgt_submeun").hide();}
}

function startmarquee(lh,speed,delay,box){
var t;
var p=false;
var o=document.getElementById(box);
o.innerHTML+=o.innerHTML;
o.onmouseover=function(){p=true}
o.onmouseout=function(){p=false}
o.scrollTop = 0;
function start(){
t=setInterval(scrolling,speed);
if(!p) o.scrollTop += 2;
}
function scrolling(){
if(o.scrollTop%lh!=0){
o.scrollTop += 2;
if(o.scrollTop>=o.scrollHeight/2) o.scrollTop = 0;
}else{
clearInterval(t);
setTimeout(start,delay);
}
}
setTimeout(start,delay);
}


function SearchSelect(id){
	$("#searchtype").prepend($("#SearchID"+id));
	$("#searchtype").find("li").each(function(){
	      $(this).hide();
    }); 
	$("#SearchID"+id).show();
	$("#SearchTypeId").val(id);
}

$(function(){	
	 $("#searchtype").mouseover( function () { 
		  $("#searchtype").find("li").each(function(){
	           $(this).show();
          }); 
	 });
	 
	 $("#searchtype").bind("mouseleave", function(){
		 $("#searchtype").find("li").each(function(){
	          $(this).hide();
         }); 
		 $("#searchtype li:nth-child(1)").show();
	 });
});

