// JavaScript Document


function leftMenuButton (k, j) {
	/*
	if ( j == 0 ) {
		setInterval ("leftMenuButton ("+k+", 1)", 100);
		return "";
	}
	*/
	
	for(i=0;i<=_menus.length;i++){
		if (_menus[i] != k && _menus[i] != 0 ){
			try {
				_div = document.getElementById ('div_'+_menus[i]);
				_button = document.getElementById ('button_'+_menus[i])
				_div.style.display = "none";
				_button.className = "submenu-link"
			}
			catch (ex) {}
		}	
	}
	
	_div = document.getElementById ('div_'+k);
	_button = document.getElementById ('button_'+k)
	
	if ( _div.style.display == "none" ) {
        _div.style.display = "";
		_button.className = "submenu-link"
	} else {
		_div.style.display = "none";
		_button.className = "submenu-link"
	}
	return false;
}


function MM_swapImgRestore() { 
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { 
  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 MM_findObj(n, d) { 
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { 
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

//rotator
var currentdate = 0;
var core = 0;
function initArray() {
this.length = initArray.arguments.length;
for (var i = 0; i < this.length; i++) {
this[i] = initArray.arguments[i];
}
}
b_link = new initArray(
"http://www.orexad.com/en",
"http://www.orexad.com/en",
"http://www.orexad.com/en",
"http://www.orexad.com/en",
"http://www.orexad.com/en",
"http://www.orexad.com/en",
"http://www.orexad.com/en",
"http://www.orexad.com/en"
);
text = new initArray(
"Orexad",
"Orexad",
"Orexad",
"Orexad",
"Orexad",
"Orexad",
"Orexad",
"Orexad"
);
image = new initArray(
"http://www.novotech.ro/img/header-img-1.jpg",
"http://www.novotech.ro/img/header-img-2.jpg",
"http://www.novotech.ro/img/header-img-3.jpg",
"http://www.novotech.ro/img/header-img-4.jpg",
"http://www.novotech.ro/img/header-img-5.jpg",
"http://www.novotech.ro/img/header-img-6.jpg",
"http://www.novotech.ro/img/header-img-7.jpg",
"http://www.novotech.ro/img/header-img-8.jpg"
);
var currentdate = new Date();
var core = currentdate.getSeconds() % image.length;
var ranimage = image[core];
var ranlink = b_link[core];
var rantext = text[core];
//end rotator
