var current = '';
function show_dropdown(id)
{
	var v = document.getElementById(id).style.display;
	if (v == "none")
	{
	  if( current!='' && current!=id)
	  {
	     document.getElementById(current).style.display = "none";
	  }
	  document.getElementById(id).style.display = "block";
	  current = id;
	}  
	else
	  document.getElementById(id).style.display = "none";
}
function open_tread(id)
{
   for( var i=0; i<sub_menus.length ; i++) {
      try {document.getElementById(sub_menus[i]).style.display = "none";} catch (e) {}
   }
   document.getElementById(id).style.display = "block";	  
}
function close_tread(id)
{
   for( var i=0; i<sub_menus.length ; i++)
      document.getElementById(sub_menus[i]).style.display = "none";
}
function swap_center_image(img)
{
  document.getElementById('center_image').src=img;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function BigImage(img,w,h)
{
  var obj_window = 
window.open(img,"","toolbar=no,directories=no,status = no,resizable=yes,menubar=no,scrollbars=auto,width="+w+", height="+h);
	obj_window.focus();
}