
// JavaScript Document
// Set slideShowSpeed (milliseconds)
var totalitems = 8
var Pic = new Array() 
var totalimages = totalitems

// Duration of crossfade (seconds)
var crossFadeDuration = 2


// Specify the image files

Pic[0] = '/images/home_corporate_facility.jpg'
Pic[1] = '/images/confined_space_entry_home.jpg'
Pic[2] = '/images/home_tank.jpg'
Pic[3] = '/images/home_waste.jpg'
Pic[4] = '/images/home_transportation.jpg'
Pic[5]='/images/emergency-spill.jpg'
Pic[6]='/images/tank-removal.jpg'
Pic[7]='/images/demolition.jpg'


// Preload the images
var preLoad = new Array()
for (i = 0; i < totalimages; i++){
   preLoad[i] = new Image()
   preLoad[i].src = Pic[i]
}
  // load QUOTES
//var quote = new Array();
//var quoteAuthor = new Array();
	var quoteSpeed = 4000
	var counter = 0
	//var totalquotes = totalitems //how many quotes there are	
 
    
  //quote[0] = "Corporate Facility";
 // quoteAuthor[0] = "<a href='group_travel.asp#Mexico'>More Information</a>";
  
     
 // quote[1] = "<b>Tank Cleaning Services</b>";
 // quoteAuthor[1] = "<a href=''>More Information</a>";
  
 // quote[2] = "<b>Waste Remediation</b>";
 // quoteAuthor[2] = "<a href=''>More Information</a>";
      
  
//  quote[3] = "<b>Transportation and Disposal</b>";
 // quoteAuthor[3] = "<a href=''>More Information</a>";
  
  


//==== RUN QUOTES

// =======================================
function LoadBoth(){
 if (document.all){
      document.images.SlideShow.style.filter="blendTrans(duration=2)"
      document.images.SlideShow.style.filter="blendTrans(duration=crossFadeDuration)"
      document.images.SlideShow.filters.blendTrans.Apply()      
   }


  //display the quotation
   
  document.images.SlideShow.src = preLoad[counter].src
  if (document.all){
     document.images.SlideShow.filters.blendTrans.Play()
   }
   
 //  if (document.getElementById("quote")) {
 //   document.getElementById("quote").innerHTML = '<p>' + quote[counter] + '</p>';
 //   document.getElementById("quote").innerHTML += '<p class="quoteBy">' + quoteAuthor[counter] + '</p>';
 
//  }
   
   counter = counter + 1
   if (counter > (totalimages-1)) counter=0  // reset back to zero
   
   var t = setTimeout('LoadBoth()',quoteSpeed)
}

// ==============================================
