 function aList(im){
        var path=im.src.substring(0, im.src.length-9);
        var img=im.src.substr(im.src.length-9);
        var div=document.getElementById('ls'+im.id);
        if(img=='tree2.gif'){
                im.src=path+'tree3.gif';
                div.style.display='none';
        }
        if(img=='tree3.gif'){
                im.src=path+'tree2.gif';
                div.style.display='';
        }
 }

 function aList3(im){
        var div=document.getElementById('i_'+im);
        var div2=document.getElementById('lsi_'+im);
        var path=div.src.substring(0, div.src.length-9);
        var img=div.src.substr(div.src.length-9);
        if(img=='tree2.gif'){
                div.src=path+'tree3.gif';
                div2.style.display='none';
        }
        if(img=='tree3.gif'){
                div.src=path+'tree2.gif';
                div2.style.display='';
        }
 }

 function aList2(im){
        var div=document.getElementById('i_'+im);
        var path=div.src.substring(0, div.src.length-9);
        div.src=path+'tree3.gif';
 }

 function doHide() {
	  var agt = navigator.userAgent.toLowerCase ();
	  var is_ie = (agt.indexOf ("ie") != -1);
	  if(document.getElementById('axcrt')){
		 document.getElementById('axcrt').style.visibility = 'hidden';
		 document.getElementById('axcrt').style.display = 'none';
		 setTimeout('doreset()',100);
		 if ( is_ie ){
		 if (document.styleSheets.length == 0) document.createStyleSheet();
		 var oSheet = document.styleSheets[0];
		 oSheet.addRule(".WCHhider", "visibility:visible");
		 }
	  }
 }

 function open_window(link,w,h) //opens new window
{
		var win = "width="+w+",height="+h+",menubar=no,location=no,resizable=yes,scrollbars=yes";
		newWin = window.open(link,'newWin',win);
		newWin.focus();
}

function open_printable_version(link) //opens new window
{
		var win = "menubar=no,location=no,resizable=yes,scrollbars=yes";
		newWin = window.open(link,'perintableWin',win);
		newWin.focus();
}

function confirmDelete(id, ask, url) //confirm order delete
{
		temp = window.confirm(ask);
		if (temp) //delete
		{
				window.location=url+id;
		}
}

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 mover(mId,set){
		mId.style.backgroundColor=set;
}

function mout(mId,set){
		mId.style.backgroundColor=set;
}

function setX()
		{
		   if(document.getElementById('axcrt')){
		   document.getElementById('axcrt').style.pixelTop = document.body.scrollTop + Math.ceil((document.body.clientHeight-100)/2);
		   }
}

function insertFlash(width,height,path,bgcolor,align,id)
{
   document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="'+width+'" height="'+height+'" id="'+id+'" align="middle">');
   document.write('<param name="allowScriptAccess" value="sameDomain">');
   document.write('<param name="movie" value="'+path+'">');
   document.write('<param name="quality" value="high">');
   document.write('<param name="bgcolor" value="'+bgcolor+'">');
   document.write('<embed src="'+path+'" quality="high" bgcolor="'+bgcolor+'" width="'+width+'" height="'+height+'" name="'+id+'" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer">');
   document.write('</object>');
} 