// Created by Ovidiu Sopa
// 15.10.2007
function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}


function preloadImages()
{
  if(document.images)
  {
    if(!document.imageArray) document.imageArray = new Array();
    var i,j = document.imageArray.length, args = preloadImages.arguments;
    
    for(i=0; i<args.length; i++)
    {
      if (args[i].indexOf("#")!=0)
      {
        document.imageArray[j] = new Image;
        document.imageArray[j++].src = args[i];
      }
    }
  }
}


function switch_layers(show_this,hide_this){	
	if(show_this != '') document.getElementById(show_this).className = 'show';
	if(hide_this != '') document.getElementById(hide_this).className = 'ascunde';
	document.getElementById(show_this).focus();
	}

function open_window(link, width, height)
{
     window.open(link,"","toolbar=0,top=0,scrollbars=yes, width="+width+",height="+height+"");
}

function confirmLink(theLink, theSqlQuery)
{
    var is_confirmed = confirm(theSqlQuery);
    if (is_confirmed) {
        theLink.href += '&is_js_confirmed=1';
    }

    return is_confirmed;
}

function printWindow(){
	navi = parseInt(navigator.appVersion)
   	if (navi >= 4) window.print()
	}


function scrollToDivID(divID){
	var divID = divID;
	eval("document.all." + divID + ".scrollIntoView(true)");
}
function scrollToTop(){
	window.scrollTo(0,0);
}


