var globIndx;

function Pop() {
window.open(popups[globIndx], null, "width=600,height=530", "scroll=no");
var strLoc = window.location;
window.navigate(strLoc);
}
//Specify random images to display 
var randomimage=new Array()
randomimage[0]="./img/PROMO_Served.gif"
//randomimage[1]="./img/PROMO_Pharmacy.gif"
//randomimage[2]="./img/PROMO_WWonWeb.gif"
randomimage[1]="./img/PROMO_Exception.gif"
randomimage[2]="./img/PROMO_Excel.gif"
randomimage[3]="./img/PROMO_Warehouse.gif"


var popups=new Array()
popups[0]="popserved.html"
//popups[1]="poppharm.html"
//popups[2]="popwow.html"
popups[1]="popexcept.html"
popups[2]="popsoftware.html"
popups[3]="popwhouse.html"


function pickImage(){
var imgobj=document.getElementById? document.getElementById("banner") : document.banner
globIndx = Math.floor(Math.random()*randomimage.length);
imgobj.src=randomimage[globIndx];
}

function loadButtons()
{
	pickImage();

	var btn = document.getElementById? document.getElementById("defBtn") : document.defBtn

	if(btn.value.indexOf('home')>-1)		
		document.home11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV1_home.gif" 			
	else
		document.home11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV0_home.gif" 
		
	if(btn.value.indexOf('services')>-1)
		document.services1131.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV1_services.gif";
	else	
		document.services1131.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV0_services.gif";

	if(btn.value.indexOf('software')>-1)
		document.software1.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV1_software.gif";
	else	
		document.software1.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV0_software.gif";

	if(btn.value.indexOf('data')>-1)
		document.data11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV1_data.gif";
	else	
		document.data11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV0_data.gif";

	if(btn.value.indexOf('online')>-1)
		document.online11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV1_online.gif";
	else	
		document.online11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV0_online.gif";
		
	if(btn.value.indexOf('contact')>-1)
		document.contact11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV1_contact.gif";
	else	
		document.contact11.src="http://www.aztec.com.au/SynovateAZTEC/ASSETS/IMAGES/NAV0_contact.gif";
}

function MM_swapImgRestore() { //v3.0
  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() { //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 MM_findObj(n, d) { //v4.0


  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 && document.getElementById)
  {
    
    x=document.getElementById(n); 
  }

  return x;
}

function MM_swapImage() { //v3.0
  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];
   }
}