

var ajax = new sack();
function whenLoading(){	
}function whenLoaded(){
}function whenInteractive(){
}function whenCompleted(){
}function get_regional(){	
	ajax.requestFile = "/Suppliers/top_country.cgi?t="+Math.random();
	ajax.method = "get";
	ajax.element = 'country_div';
	//ajax.onLoading = whenLoading;
	//ajax.onLoaded = whenLoaded; 
	//ajax.onInteractive = whenInteractive;
	ajax.onCompletion = whenCompleted;
	ajax.runAJAX("site=www");
}
//get_regional();



var mopen=false;
function openm()
{
 if (mopen)
 {
 document.getElementById('country_div').className="toocle1";
 }else
 {
  document.getElementById('country_div').className="toocle2";
 }
 mopen=!mopen;
}

function cancel(){
 openm();
}
function mdown(e)
{
var targ;
if (!e)
  {
  var e = window.event;
  }
if (e.target)
  {
  targ = e.target;
  }
else if (e.srcElement)
  {
  targ = e.srcElement;
  }
if (targ.nodeType == 3) // defeat Safari bug
  {
  targ = targ.parentNode;
  }
var tname;
//tname=targ.tagName;
tname=targ.id;

if(tname.indexOf('country_div')==-1){
	//alert("You clicked on a " + tname + " element.");
   if(mopen)   openm(); 
  }
}

function country_show(country)
{  	
 var country_link = country.replace(new RegExp(" ","gm"),"_");
 this.location.href="/" + country_link + "/main.html";
 //document.getElementById('country_div2').innerHTML=country + " &gt;&gt;"; 
 ////document.getElementById('Products').href="/"+ country_link + "/Products/"; 
 //document.getElementById('Suppliers').href="/"+ country_link + "/Suppliers/"; 
 ////document.getElementById('Sourcing').href="/"+ country_link + "/Sourcing/"; 
 //document.getElementById('Buyers').href="/"+ country_link + "/Buyers/"; 
 //document.getElementById('country').value=country; 
 openm(); 
}

if(regional){
	//country_show(regional);
	//openm();
}
