 //Global Variable to hold the current Top Menu TD

 var currentTopMenuTD;
 var subMenuDisplayed;
 
 subMenuDisplayed = false;
 currentTopMenuTD = "";

  function showSubMenu(aTableData, aTopMenuIndex, aSubMenuDiv) 
  {}

 function showSubMenu2(aTableData, aTopMenuIndex) 
  {
  var proceed;
  var subMenuTextArray;
  var subMenuLinkArray;

	//alert("inshowSubMenu2");

  hideSubMenu2();

   var aSubMenuDiv;
   aSubMenuDiv = document.getElementById("topNavSubItems");

  if (!subMenuDisplayed)
  {
  proceed = false;

  //Change the color of the cell in the main menu
  aTableData.bgColor = "#000000";
  currentTopMenuTD = aTableData.id;
  switch(aTopMenuIndex){
  case 1:
	  //Text
	  subMenuTextArray = new Array();
	  subMenuTextArray[0] = "Feature Extraction";
	  subMenuTextArray[1] = "Geo Specific Modelling";
	  subMenuTextArray[2] = "Urban Ops & Visualization";
	  //subMenuTextArray[3] = "Urban Terrain Vizualization";
	  //links
	  subMenuLinkArray = new Array();
	  subMenuLinkArray[0] = "http://www.objectraku.com/06_prodserv/fti_index.htm";
	  subMenuLinkArray[1] = "http://www.objectraku.com/06_solutions/geospecificmodelling.htm";
	  subMenuLinkArray[2] = "http://www.objectraku.com/06_solutions/urbanterrainviz.htm";
	  //subMenuLinkArray[3] = "http://www.objectraku.com/06_solutions/urbanterrainviz.htm";
	  proceed = true;
	  break;
  
  case 2:
  	  //Text
	  subMenuTextArray = new Array();  
	  subMenuTextArray[0] = "LiDAR FTI";
	  subMenuTextArray[1] = "Sextant";
	  subMenuTextArray[2] = "Geo Services";
	  subMenuTextArray[3] = "Symbology";

	  
	  
	  
	  //Links
	  subMenuLinkArray = new Array();
	  subMenuLinkArray[0] = "http://www.objectraku.com/06_prodserv/fti_index.htm";	
	  subMenuLinkArray[1] = "http://www.objectraku.com/06_prodserv/sextantindex.htm";	  
	  subMenuLinkArray[2] = "http://www.objectraku.com/06_prodserv/geoservicesindex.htm";
	  subMenuLinkArray[3] = "http://www.objectraku.com/06_prodserv/symbolsindex.htm";	  
	  //subMenuLinkArray[1] = "http://www.objectraku.com/06_prodserv/componentsindex.htm";
	  //subMenuLinkArray[2] = "http://www.objectraku.com/06_prodserv/mrc/mrcpackage.htm";
 	  //subMenuLinkArray[5] = "http://www.objectraku.com/06_prodserv/fti_index.htm";
	  proceed = true;
	  break;

  case 3:
  	  //Text
	  subMenuTextArray = new Array();  
	  subMenuTextArray[0] = "News";
	  subMenuTextArray[1] = "Profile";
	  subMenuTextArray[2] = "Testimonials";
	  subMenuTextArray[3] = "Customers";
	  subMenuTextArray[4] = "Partners";
	  subMenuTextArray[5] = "Contact";
	  //Links
	  subMenuLinkArray = new Array();
	  subMenuLinkArray[0] = "http://www.objectraku.com/06_company/news/news2010.htm";
	  subMenuLinkArray[1] = "http://www.objectraku.com/06_company/profile.htm";
	  subMenuLinkArray[2] = "http://www.objectraku.com/06_company/testimonials.htm";
	  subMenuLinkArray[3] = "http://www.objectraku.com/06_company/customers.htm";
	  subMenuLinkArray[4] = "http://www.objectraku.com/06_company/partners.htm";
	  subMenuLinkArray[5] = "http://www.objectraku.com/06_company/contact.htm";
	  proceed = true;
	  break;

  case 4:
  	  //Text
	  subMenuTextArray = new Array();  
	  subMenuTextArray[0] = "Demos";
	  subMenuTextArray[1] = "Training";
	  subMenuTextArray[2] = "Gallery";
	  subMenuTextArray[3] = "Online Resources";
	  subMenuTextArray[4] = "Tech Support";
	  //Links
	  subMenuLinkArray = new Array();
	  subMenuLinkArray[0] = "http://www.objectraku.com/06_support/demos.htm";
	  subMenuLinkArray[1] = "http://www.objectraku.com/06_support/workshop.htm";
	  subMenuLinkArray[2] = "http://www.objectraku.com/06_support/gallery.htm";
	  subMenuLinkArray[3] = "http://www.objectraku.com/06_support/resources.htm";
	  subMenuLinkArray[4] = "http://www.objectraku.com/06_support/techsupport.htm";
	  proceed = true;
	  break;
  	  
  }//End Switch

  //alert('before proceed' + proceed);
  if (proceed)
  {
   
  var tmpContent;
  var oTable = document.createElement("TABLE");
  var oTBody0 = document.createElement("TBODY");
  var oRow = document.createElement("TR");
  var oCell;
  var oAnchor;
  var oText;

  // Set oTables properties
  oTable.id = "subMenuTable";
  oTable.bgColor = "#000000";
  //oTable.align = "center";
  oTable.valign = "top"; 
  oTable.border = 0; 
  oTable.cellspacing = 0;
  oTable.width = "600";

  // Set oRows properties
  oRow.align = "center"; 
  oRow.valign = "top"; 

  // Create required cells, set properties and text, insert into row
  oCell = document.createElement("TD");

  oRow.appendChild(oCell);

  for (i=0; i<subMenuTextArray.length; i++)
  {
  oCell = document.createElement("TD");
  oAnchor = document.createElement("A");
  oText = document.createTextNode(subMenuTextArray[i]);
  oAnchor.href = subMenuLinkArray[i];
  oAnchor.appendChild(oText);
  oCell.appendChild(oAnchor);
  oRow.appendChild(oCell);
  }

  oCell = document.createElement("TD");

  oRow.appendChild(oCell);


  // Insert the created elements into oTable.
  oTBody0.appendChild(oRow);
  oTable.appendChild(oTBody0);
  aSubMenuDiv.appendChild(oTable);

  subMenuDisplayed = true;
  } //End if (proceed)
  } //End if (subMenuDisplayed)
};  //End function showSubMenu

function hideSubMenu() 
  {
  }
function hideSubMenu2() 
  {
   var oTable;
   var i;
   var aSubMenuDiv;
   var cTD;
   //alert("inhideSubMenu2 + " + subMenuDisplayed);
   
   if (subMenuDisplayed)
    {
    oTable = document.getElementById("subMenuTable");
    if(oTable)
    {
    aSubMenuDiv = oTable.parentNode;
    aSubMenuDiv.removeChild(oTable);
     }
     //alert(currentTopMenuTD);
     cTD = document.getElementById(currentTopMenuTD);
     cTD.bgColor="#c3624a";
    }
    subMenuDisplayed = false;
    

  };

  function processMainMenuEvent(evt) {
      evt = (evt) ? evt : ((window.event) ? window.event : "")
      if (evt) {
          var elem = (evt.target) ? evt.target : evt.srcElement
  
    switch(elem.parentNode.id){
    case "SolutionsTD":
  	  //alert(elem.parentNode.id)
  	  showSubMenu2(elem.parentNode, 1)
  	  break;
  
    case "ProdServTD":
  	  //alert(elem.parentNode.id)
  	  showSubMenu2(elem.parentNode, 2)
  	  break;
  
    case "SupportTD":
  	  //alert(elem.parentNode.id)
  	  showSubMenu2(elem.parentNode, 4)
  	  break;
  
    case "CompanyTD":
  	  //alert(elem.parentNode.id)
  	  showSubMenu2(elem.parentNode, 3)
  	  break;
  
    }//End Switch
  
      }
}

  function rebuildTopMenu() 
    {

     var aTopMenuTD;
     var oSpan;
     var oText;
     var nText;

     aTopMenuTD = document.getElementById("SolutionsTD");
     oText =  aTopMenuTD.firstChild;
     if(oText)
     	{
     	aTopMenuTD.removeChild(oText);
	nText = document.createTextNode(" SOLUTIONS ");
	oSpan = document.createElement("SPAN");
	oSpan.onmouseover = processMainMenuEvent;
	oSpan.appendChild(nText);
	aTopMenuTD.appendChild(oSpan);
	}

     aTopMenuTD = document.getElementById("ProdServTD");
     oText =  aTopMenuTD.firstChild;
     if(oText)
        {
        aTopMenuTD.removeChild(oText);
    	nText = document.createTextNode(" PRODUCTS & SERVICES ");
    	oSpan = document.createElement("SPAN");
    	oSpan.onmouseover = processMainMenuEvent;
    	oSpan.appendChild(nText);
    	aTopMenuTD.appendChild(oSpan);
	}

     aTopMenuTD = document.getElementById("SupportTD");
     oText =  aTopMenuTD.firstChild;
     if(oText)
        {
        aTopMenuTD.removeChild(oText);
    	nText = document.createTextNode(" SUPPORT ");
    	oSpan = document.createElement("SPAN");
    	oSpan.onmouseover = processMainMenuEvent;
    	oSpan.appendChild(nText);
    	aTopMenuTD.appendChild(oSpan);
	}

     aTopMenuTD = document.getElementById("CompanyTD");
     oText =  aTopMenuTD.firstChild;
     if(oText)
        {
        aTopMenuTD.removeChild(oText);
    	nText = document.createTextNode(" COMPANY ");
    	oSpan = document.createElement("SPAN");
    	oSpan.onmouseover = processMainMenuEvent;
    	oSpan.appendChild(nText);
    	aTopMenuTD.appendChild(oSpan);
	}

      
  
  };

 function buildNewsDiv() 
  {
   var oAnchor;
   var oText;
   var oBR;
   var i;
   var newsTextArray;
   var newsLinkArray;

   rebuildTopMenu();	//Do this here as it gets run by every page

   var aNewsDiv=document.getElementById("news_body");


 //Edit the text and Link arrys below to update the news on all pages

  newsTextArray = new Array();
  newsTextArray[0] = "Sextant Workshops announced for Spring 2011";
  newsTextArray[1] = "Object Raku adding beta partners for FTI";
  newsTextArray[2] = "Object Raku announces Research Collaboration with SFU";
  newsTextArray[3] = "Raku Symbol Server build 3.0.32 released";
  
  //links
  newsLinkArray = new Array();
  newsLinkArray[0] = "http://www.objectraku.com/06_company/news/news2011.htm";
  newsLinkArray[1] = "http://www.objectraku.com/06_company/news/news2010.htm";
  newsLinkArray[2] = "http://www.objectraku.com/06_company/news/news2010.htm";
  newsLinkArray[3] = "http://www.objectraku.com/06_company/news/news2010.htm";
  //

  for (i=0; i<newsTextArray.length; i++)
  {
   oAnchor = document.createElement("A");
   oBR = document.createElement("BR");
   oText = document.createTextNode(newsTextArray[i]);
   oAnchor.href = newsLinkArray[i];
   oAnchor.appendChild(oText);
   aNewsDiv.appendChild(oAnchor);
   aNewsDiv.appendChild(oBR);
   }

  setUpFooter();
  };

  function setUpHomePage() 
  {
   var mainImageDiv=document.getElementById("LargeCenterBannerImage");
   
   var SplashFiles = new Array();
   SplashFiles[0] = "url(image/general/Splashbanner1.gif)";
   SplashFiles[1] = "url(image/general/Splashbanner2.gif)";
   SplashFiles[2] = "url(image/general/Splashbanner1.gif)";
   SplashFiles[3] = "url(image/general/Splashbanner2.gif)";
   SplashFiles[4] = "url(image/general/Splashbanner1.gif)";
   SplashFiles[5] = "url(image/general/Splashbanner2.gif)";
   var imgCt = SplashFiles.length;
   var randomNum = Math.floor((Math.random() * imgCt));
   mainImageDiv.style.backgroundImage = SplashFiles[randomNum];
   buildNewsDiv();

  };

  function setUpFooter() 
    {
     var footerDiv = document.getElementById("footer");
     var fAnchor;
     var oText;
     footerDiv.innerText = "";
     fAnchor = document.createElement("A");
     oText = document.createTextNode("Copyright Object Raku Technology Inc. 2012");
     fAnchor.href = "http://www.objectraku.com/06_company/termsofuse.htm";
     fAnchor.appendChild(oText);
     footerDiv.appendChild(fAnchor);     
  
     };


//New Slide Show for gallery
function slide(src,link,text,target,attr) {
  // This is the constructor function for the slide object.
  // It is called automatically when you create a new slide object.
  // For example:
  // s = new slide();

  // Image URL
  this.src = src;

  // Link URL
  this.link = link;

  // Text to display
  this.text = text;

  // Name of the target window ("_blank")
  this.target = target;

  // Custom duration for the slide, in milliseconds.
  // This is an optional parameter.
  // this.timeout = 3000

  // Attributes for the target window:
  // width=n,height=n,resizable=yes or no,scrollbars=yes or no,
  // toolbar=yes or no,location=yes or no,directories=yes or no,
  // status=yes or no,menubar=yes or no,copyhistory=yes or no
  // Example: "width=200,height=300"
  this.attr = attr;

  // Create an image object for the slide
  if (document.images) {
    this.image = new Image();
  }

  // Flag to tell when load() has already been called
  this.loaded = false;

  //--------------------------------------------------
  this.load = function() {
    // This method loads the image for the slide

    if (!document.images) { return; }

    if (!this.loaded) {
      this.image.src = this.src;
      this.loaded = true;
    }
  }

  //--------------------------------------------------
  this.hotlink = function() {
    // This method jumps to the slide's link.
    // If a window was specified for the slide, then it opens a new window.

    var mywindow;

    // If this slide does not have a link, do nothing
    if (!this.link) return;

    // Open the link in a separate window?
    if (this.target) {

      // If window attributes are specified,
      // use them to open the new window
      if (this.attr) {
        mywindow = window.open(this.link, this.target, this.attr);
  
      } else {
        // If window attributes are not specified, do not use them
        // (this will copy the attributes from the originating window)
        mywindow = window.open(this.link, this.target);
      }

      // Pop the window to the front
      if (mywindow && mywindow.focus) mywindow.focus();

    } else {
      // Open the link in the current window
      location.href = this.link;
    }
  }
}

//==================================================
// slideshow object
//==================================================
function slideshow( slideshowname ) {
  // This is the constructor function for the slideshow object.
  // It is called automatically when you create a new object.
  // For example:
  // ss = new slideshow("ss");

  // Name of this object
  // (required if you want your slideshow to auto-play)
  // For example, "SLIDES1"
  this.name = slideshowname;

  // When we reach the last slide, should we loop around to start the
  // slideshow again?
  this.repeat = true;

  // Number of images to pre-fetch.
  // -1 = preload all images.
  //  0 = load each image is it is used.
  //  n = pre-fetch n images ahead of the current image.
  // I recommend preloading all images unless you have large
  // images, or a large amount of images.
  this.prefetch = -1;

  // IMAGE element on your HTML page.
  // For example, document.images.SLIDES1IMG
  this.image;

  // ID of a DIV element on your HTML page that will contain the text.
  // For example, "slides2text"
  // Note: after you set this variable, you should call
  // the update() method to update the slideshow display.
  this.textid;

  // TEXTAREA element on your HTML page.
  // For example, document.SLIDES1FORM.SLIDES1TEXT
  // This is a depracated method for displaying the text,
  // but you might want to supply it for older browsers.
  this.textarea;

  // Milliseconds to pause between slides.
  // Individual slides can override this.
  this.timeout = 3000;

  // Hook functions to be called before and after updating the slide
  // this.pre_update_hook = function() { }
  // this.post_update_hook = function() { }

  // These are private variables
  this.slides = new Array();
  this.current = 0;
  this.timeoutid = 0;

  //--------------------------------------------------
  // Public methods
  //--------------------------------------------------
  this.add_slide = function(slide) {
    // Add a slide to the slideshow.
    // For example:
    // SLIDES1.add_slide(new slide("s1.jpg", "link.html"))
  
    var i = this.slides.length;
  
    // Prefetch the slide image if necessary
    if (this.prefetch == -1) {
      slide.load();
    }

    this.slides[i] = slide;
  }

  //--------------------------------------------------
  this.play = function(timeout) {
    // This method implements the automatically running slideshow.
    // If you specify the "timeout" argument, then a new default
    // timeout will be set for the slideshow.
  
    // Make sure we're not already playing
    this.pause();
  
    // If the timeout argument was specified (optional)
    // then make it the new default
    if (timeout) {
      this.timeout = timeout;
    }
  
    // If the current slide has a custom timeout, use it;
    // otherwise use the default timeout
    if (typeof this.slides[ this.current ].timeout != 'undefined') {
      timeout = this.slides[ this.current ].timeout;
    } else {
      timeout = this.timeout;
    }

    // After the timeout, call this.loop()
    this.timeoutid = setTimeout( this.name + ".loop()", timeout);
  }

  //--------------------------------------------------
  this.pause = function() {
    // This method stops the slideshow if it is automatically running.
  
    if (this.timeoutid != 0) {

      clearTimeout(this.timeoutid);
      this.timeoutid = 0;

    }
  }

  //--------------------------------------------------
  this.update = function() {
    // This method updates the slideshow image on the page

    // Make sure the slideshow has been initialized correctly
    if (! this.valid_image()) { return; }
  
    // Call the pre-update hook function if one was specified
    if (typeof this.pre_update_hook == 'function') {
      this.pre_update_hook();
    }

    // Convenience variable for the current slide
    var slide = this.slides[ this.current ];

    // Determine if the browser supports filters
    var dofilter = false;
    if (this.image &&
        typeof this.image.filters != 'undefined' &&
        typeof this.image.filters[0] != 'undefined') {

      dofilter = true;

    }

    // Load the slide image if necessary
    slide.load();
  
    // Apply the filters for the image transition
    if (dofilter) {

      // If the user has specified a custom filter for this slide,
      // then set it now
      if (slide.filter &&
          this.image.style &&
          this.image.style.filter) {

        this.image.style.filter = slide.filter;

      }
      this.image.filters[0].Apply();
    }

    // Update the image.
    this.image.src = slide.image.src;

    // Play the image transition filters
    if (dofilter) {
      this.image.filters[0].Play();
    }

    // Update the text
    this.display_text();

    // Call the post-update hook function if one was specified
    if (typeof this.post_update_hook == 'function') {
      this.post_update_hook();
    }

    // Do we need to pre-fetch images?
    if (this.prefetch > 0) {

      var next, prev, count;

      // Pre-fetch the next slide image(s)
      next = this.current;
      prev = this.current;
      count = 0;
      do {

        // Get the next and previous slide number
        // Loop past the ends of the slideshow if necessary
        if (++next >= this.slides.length) next = 0;
        if (--prev < 0) prev = this.slides.length - 1;

        // Preload the slide image
        this.slides[next].load();
        this.slides[prev].load();

        // Keep going until we have fetched
        // the designated number of slides

      } while (++count < this.prefetch);
    }
  }

  //--------------------------------------------------
  this.goto_slide = function(n) {
    // This method jumpts to the slide number you specify.
    // If you use slide number -1, then it jumps to the last slide.
    // You can use this to make links that go to a specific slide,
    // or to go to the beginning or end of the slideshow.
    // Examples:
    // onClick="myslides.goto_slide(0)"
    // onClick="myslides.goto_slide(-1)"
    // onClick="myslides.goto_slide(5)"
  
    if (n == -1) {
      n = this.slides.length - 1;
    }
  
    if (n < this.slides.length && n >= 0) {
      this.current = n;
    }
  
    this.update();
  }


  //--------------------------------------------------
  this.goto_random_slide = function(include_current) {
    // Picks a random slide (other than the current slide) and
    // displays it.
    // If the include_current parameter is true,
    // then 
    // See also: shuffle()

    var i;

    // Make sure there is more than one slide
    if (this.slides.length > 1) {

      // Generate a random slide number,
      // but make sure it is not the current slide
      do {
        i = Math.floor(Math.random()*this.slides.length);
      } while (i == this.current);
 
      // Display the slide
      this.goto_slide(i);
    }
  }


  //--------------------------------------------------
  this.next = function() {
    // This method advances to the next slide.

    // Increment the image number
    if (this.current < this.slides.length - 1) {
      this.current++;
    } else if (this.repeat) {
      this.current = 0;
    }

    this.update();
  }


  //--------------------------------------------------
  this.previous = function() {
    // This method goes to the previous slide.
  
    // Decrement the image number
    if (this.current > 0) {
      this.current--;
    } else if (this.repeat) {
      this.current = this.slides.length - 1;
    }
  
    this.update();
  }


  //--------------------------------------------------
  this.shuffle = function() {
    // This method randomly shuffles the order of the slides.

    var i, i2, slides_copy, slides_randomized;

    // Create a copy of the array containing the slides
    // in sequential order
    slides_copy = new Array();
    for (i = 0; i < this.slides.length; i++) {
      slides_copy[i] = this.slides[i];
    }

    // Create a new array to contain the slides in random order
    slides_randomized = new Array();

    // To populate the new array of slides in random order,
    // loop through the existing slides, picking a random
    // slide, removing it from the ordered list and adding it to
    // the random list.

    do {

      // Pick a random slide from those that remain
      i = Math.floor(Math.random()*slides_copy.length);

      // Add the slide to the end of the randomized array
      slides_randomized[ slides_randomized.length ] =
        slides_copy[i];

      // Remove the slide from the sequential array,
      // so it cannot be chosen again
      for (i2 = i + 1; i2 < slides_copy.length; i2++) {
        slides_copy[i2 - 1] = slides_copy[i2];
      }
      slides_copy.length--;

      // Keep going until we have removed all the slides

    } while (slides_copy.length);

    // Now set the slides to the randomized array
    this.slides = slides_randomized;
  }


  //--------------------------------------------------
  this.get_text = function() {
    // This method returns the text of the current slide
  
    return(this.slides[ this.current ].text);
  }


  //--------------------------------------------------
  this.get_all_text = function(before_slide, after_slide) {
    // Return the text for all of the slides.
    // For the text of each slide, add "before_slide" in front of the
    // text, and "after_slide" after the text.
    // For example:
    // document.write("<ul>");
    // document.write(s.get_all_text("<li>","\n"));
    // document.write("<\/ul>");
  
    all_text = "";
  
    // Loop through all the slides in the slideshow
    for (i=0; i < this.slides.length; i++) {
  
      slide = this.slides[i];
    
      if (slide.text) {
        all_text += before_slide + slide.text + after_slide;
      }
  
    }
  
    return(all_text);
  }


  //--------------------------------------------------
  this.display_text = function(text) {
    // Display the text for the current slide
  
    // If the "text" arg was not supplied (usually it isn't),
    // get the text from the slideshow
    if (!text) {
      text = this.slides[ this.current ].text;
    }
  
    // If a textarea has been specified,
    // then change the text displayed in it
    if (this.textarea && typeof this.textarea.value != 'undefined') {
      this.textarea.value = text;
    }

    // If a text id has been specified,
    // then change the contents of the HTML element
    if (this.textid) {

      r = this.getElementById(this.textid);
      if (!r) { return false; }
      if (typeof r.innerHTML == 'undefined') { return false; }

      // Update the text
      r.innerHTML = text;
    }
  }


  //--------------------------------------------------
  this.hotlink = function() {
    // This method calls the hotlink() method for the current slide.
  
    this.slides[ this.current ].hotlink();
  }

  }







 /***********************************************
 * Ultimate Fade-In Slideshow (v1.5): © Dynamic Drive (http://www.dynamicdrive.com)
 * This notice MUST stay intact for legal use
 * Visit http://www.dynamicdrive.com/ for this script and 100s more.
 ***********************************************/
  
 var fadeimages=new Array()
 //SET IMAGE PATHS. Extend or contract array as needed
 fadeimages[0]=["image/company/customers/USMC.jpg", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[1]=["image/company/customers/Lockmart.jpg", "06_company/customers.htm", "_new"] //image with link syntax
 fadeimages[2]=["image/company/customers/CFJIC_logo_small.jpg", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[3]=["image/company/customers/iasfos_med_websm.gif", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[4]=["image/company/customers/CDN_Army_logo3.jpg", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[5]=["image/company/customers/Ratheon_logo_small.jpg", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[6]=["image/company/customers/Boeingsm.gif", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[7]=["image/company/customers/ngasm.gif", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[8]=["image/company/customers/tpc_sm2.gif", "06_company/customers.htm", "_new"] //plain image syntax
 fadeimages[9]=["image/company/customers/GD_logo1.jpg", "06_company/customers.htm", "_new"] //plain image syntax  
  
 //var fadeimages2=new Array() //2nd array set example. Remove or add more sets as needed.
 //SET IMAGE PATHS. Extend or contract array as needed
 //fadeimages2[0]=["../image/support/gallery/2storey_textured_irregular_terrain.jpg", //"../image/support/gallery/2storey_textured_irregular_terrain.jpg", "_new"] //plain image syntax
 //fadeimages2[1]=["../image/support/gallery/3dPic1x.jpg", "../image/support/gallery/3dPic1x.jpg", "_new"] //plain image syntax
 //fadeimages2[2]=["../image/support/gallery/AftonCanyonImageDrape.jpg", "../image/support/gallery/AftonCanyonImageDrape.jpg", "_new"] //plain image syntax
 //fadeimages2[3]=["../image/support/gallery/AssayOffice.jpg", "../image/support/gallery/AssayOffice.jpg", "_new"] //plain image syntax
 //fadeimages2[4]=["../image/support/gallery/BiLevel_Inset_Concourse.jpg", "../image/support/gallery/BiLevel_Inset_Concourse.jpg", "_new"] //plain image syntax
 //fadeimages2[5]=["../image/support/gallery/Bldg75_Label_InteriorWallswFloorBrown2small.jpg", "../image/support/gallery/Bldg75_Label_InteriorWallswFloorBrown2small.jpg", "_new"] //plain image syntax
 //fadeimages2[6]=["../image/support/gallery/BuildingTextured_CarReflection.jpg", "../image/support/gallery/BuildingTextured_CarReflection.jpg", "_new"]
 //fadeimages2[7]=["../image/support/gallery/BuildingTextured_TreeReflectionsX.jpg", "../image/support/gallery/BuildingTextured_TreeReflectionsX.jpg", "_new"]
 //fadeimages2[8]=["../image/support/gallery/CampLejeuneMOUT_V2_Bldg8_9_inset.jpg", "CampLejeuneMOUT_V2_Bldg8_9_inset.jpg", "_new"]
 //fadeimages2[9]=["../image/support/gallery/CampLejeuneMOUT_V2_rubble_inset.jpg", "../image/support/gallery/CampLejeuneMOUT_V2_rubble_inset.jpg", "_new"]
 //fadeimages2[10]=["../image/support/gallery/CampLejeuneMOUT_V2_sandbags_inset.jpg", "../image/support/gallery/CampLejeuneMOUT_V2_sandbags_inset.jpg", "_new"]
 //fadeimages2[11]=["../image/support/gallery/CampLejeuneMOUT_V2_viewBldg8_9_inset.jpg", "../image/support/gallery/CampLejeuneMOUT_V2_viewBldg8_9_inset.jpg", "_new"]
 //fadeimages2[12]=["../image/support/gallery/CampLejeuneMOUT_V2_wreck_inset.jpg", "../image/support/gallery/CampLejeuneMOUT_V2_wreck_inset.jpg", "_new"]
 //fadeimages2[13]=["../image/support/gallery/CBRN_Lab2.jpg", "../image/support/gallery/CBRN_Lab2.jpg", "_new"]
 //fadeimages2[14]=["../image/support/gallery/CBRN_Lab.jpg", "../image/support/gallery/CBRN_Lab.jpg", "_new"]
 //fadeimages2[15]=["../image/support/gallery/Picture4x.jpg", "../image/support/gallery/Picture4x.jpg", "_new"]
 //fadeimages2[16]=["../image/support/gallery/Crystal City Subway.jpg", "../image/support/gallery/Crystal City Subway.jpg", "_new"]
 //fadeimages2[17]=["../image/support/gallery/DamagedBuilding1.jpg", "../image/support/gallery/DamagedBuilding1.jpg", "_new"]
 //fadeimages2[18]=["../image/support/gallery/DawnatKnox.jpg", "../image/support/gallery/DawnatKnox.jpg", "_new"]
 //fadeimages2[19]=["../image/support/gallery/DRDC_bldg75_insidex.jpg", "../image/support/gallery/DRDC_bldg75_insidex.jpg", "_new"]
 //fadeimages2[20]=["../image/support/gallery/DRDC_overhead.jpg", "../image/support/gallery/DRDC_overhead.jpg", "_new"]
 //fadeimages2[21]=["../image/support/gallery/Hyson at JCFAWE2.jpg", "../image/support/gallery/Hyson at JCFAWE2.jpg", "_new"]
 //fadeimages2[22]=["../image/support/gallery/Inlet 3.jpg", "../image/support/gallery/Inlet 3.jpg", "_new"]
 //fadeimages2[23]=["../image/support/gallery/Jail2.jpg", "../image/support/gallery/Jail2.jpg", "_new"]
 //fadeimages2[24]=["../image/support/gallery/JMR Street w_logo.jpg", "../image/support/gallery/JMR Street w_logo.jpg", "_new"]
 //fadeimages2[25]=["../image/support/gallery/Knox_SouthfromtheBank.jpg", "../image/support/gallery/Knox_SouthfromtheBank.jpg", "_new"]
 //fadeimages2[26]=["../image/support/gallery/MiscSofa.jpg", "../image/support/gallery/MiscSofa.jpg", "_new"]
 //fadeimages2[27]=["../image/support/gallery/NewKabul3Dx.jpg", "../image/support/gallery/NewKabul3Dx.jpg", "_new"]
 //fadeimages2[28]=["../image/support/gallery/NightVisionatKnox.jpg", "../image/support/gallery/NightVisionatKnox.jpg", "_new"]
 //fadeimages2[29]=["../image/support/gallery/OtterbeinChurchFinal.jpg", "../image/support/gallery/OtterbeinChurchFinal.jpg", "_new"]
 //fadeimages2[30]=["../image/support/gallery/Pendleton1V2.jpg", "../image/support/gallery/Pendleton1V2.jpg", "_new"]
 //fadeimages2[31]=["../image/support/gallery/Phoenix_PortGastin3x.jpg", "../image/support/gallery/Phoenix_PortGastin3x.jpg", "_new"]
 //fadeimages2[32]=["../image/support/gallery/Port04x.jpg", "../image/support/gallery/Port04x.jpg", "_new"]
 //fadeimages2[33]=["../image/support/gallery/QualcommNewestx.jpg", "../image/support/gallery/QualcommNewestx.jpg", "_new"]
 //fadeimages2[34]=["../image/support/gallery/Recruit1x_med.jpg", "../image/support/gallery/Recruit1x_med.jpg", "_new"]
 //fadeimages2[35]=["../image/support/gallery/Recruit4_med.jpg", "../image/support/gallery/Recruit4_med.jpg", "_new"]
 //fadeimages2[36]=["../image/support/gallery/semibusonbridge.jpg", "../image/support/gallery/semibusonbridge.jpg", "_new"]
 //fadeimages2[37]=["../image/support/gallery/Sextant Buildings_3DSymbols_2small_labelsX.jpg", "../image/support/gallery/Sextant Buildings_3DSymbols_2small_labelsX.jpg", "_new"]
 //fadeimages2[38]=["../image/support/gallery/SextantHUD1x.jpg", "../image/support/gallery/SextantHUD1x.jpg", "_new"]
 //fadeimages2[39]=["../image/support/gallery/Smoke from the station.jpg", "../image/support/gallery/Smoke from the station.jpg", "_new"]
 //fadeimages2[40]=["../image/support/gallery/Smoke_from_Subway3.jpg", "../image/support/gallery/Smoke_from_Subway3.jpg", "_new"]
 //fadeimages2[41]=["../image/support/gallery/Subway2.jpg", "../image/support/gallery/Subway2.jpg", "_new"]
 //fadeimages2[42]=["../image/support/gallery/symbols_1.gif", "../image/support/gallery/symbols_1.gif", "_new"]
 //fadeimages2[43]=["../image/support/gallery/TEPwLejeuneWreck.jpg", "../image/support/gallery/TEPwLejeuneWreck.jpg", "_new"]
 //fadeimages2[44]=["../image/support/gallery/Terrain DrapeX.jpg", "../image/support/gallery/Terrain DrapeX.jpg", "_new"]
 //fadeimages2[45]=["../image/support/gallery/TownHouse1.jpg", "../image/support/gallery/TownHouse1.jpg", "_new"]
 //fadeimages2[46]=["../image/support/gallery/UAV_AirRouteWith4SensorViews.jpg", "../image/support/gallery/UAV_AirRouteWith4SensorViews.jpg", "_new"]
 //fadeimages2[47]=["../image/support/gallery/UAVHPP.jpg", "../image/support/gallery/UAVHPP.jpg", "_new"]
 //fadeimages2[48]=["../image/support/gallery/Undertakers.jpg", "../image/support/gallery/Undertakers.jpg", "_new"]
 //fadeimages2[49]=["../image/support/gallery/Vancouver7a.jpg", "../image/support/gallery/Vancouver7a.jpg", "_new"]
 //fadeimages2[50]=["../image/support/gallery/VancouverDowntown.jpg", "../image/support/gallery/VancouverDowntown.jpg", "_new"]
 //fadeimages2[51]=["../image/support/gallery/VectorData.jpg", "../image/support/gallery/VectorData.jpg", "_new"]
 //fadeimages2[52]=["../image/support/gallery/VehicleAmbulance.jpg", "../image/support/gallery/VehicleAmbulance.jpg", "_new"]
 //fadeimages2[53]=["../image/support/gallery/View from the bow.jpg", "../image/support/gallery/View from the bow.jpg", "_new"]
 //fadeimages2[54]=["../image/support/gallery/ViewFromEscalatorx.jpg", "../image/support/gallery/ViewFromEscalatorx.jpg", "_new"]
 //fadeimages2[55]=["../image/support/gallery/WorldSeries2002.jpg", "../image/support/gallery/WorldSeries2002.jpg", "_new"]
 //fadeimages2[56]=["../image/support/gallery/WreckedChurch_WaterTower.jpg", "../image/support/gallery/WreckedChurch_WaterTower.jpg", "_new"]


 //fadeimages2[1]=["photo2.jpg", "http://www.cssdrive.com", ""] //image with link syntax
 //fadeimages2[2]=["photo3.jpg", "http://www.javascriptkit.com", "_new"] //image with link and target syntax
  
 var fadebgcolor="white"
 var fadeWD=550
  
 ////NO need to edit beyond here/////////////
  
 var fadearray=new Array() //array to cache fadeshow instances
 var fadeclear=new Array() //array to cache corresponding clearinterval pointers
  
 var dom=(document.getElementById) //modern dom browsers
 var iebrowser=document.all
  
 function fadeshow(theimages, fadewidth, fadeheight, borderwidth, delay, pause, displayorder){
 this.pausecheck=pause
 this.mouseovercheck=0
 this.delay=delay
 this.degree=10 //initial opacity degree (10%)
 this.curimageindex=0
 this.nextimageindex=1
 fadearray[fadearray.length]=this
 fadeWD=fadewidth
 this.slideshowid=fadearray.length-1
 this.canvasbase="canvas"+this.slideshowid
 this.curcanvas=this.canvasbase+"_0"
 if (typeof displayorder!="undefined")
 theimages.sort(function() {return 0.5 - Math.random();}) //thanks to Mike (aka Mwinter) :)
 this.theimages=theimages
 this.imageborder=parseInt(borderwidth)
 this.postimages=new Array() //preload images
 for (p=0;p<theimages.length;p++){
 this.postimages[p]=new Image()
 this.postimages[p].src=theimages[p][0]
 }
  
 var fadewidth=fadewidth+this.imageborder*2
 var fadeheight=fadeheight+this.imageborder*2
  
 if (iebrowser&&dom||dom) //if IE5+ or modern browsers (ie: Firefox)
 document.write('<div id="master'+this.slideshowid+'" style="position:relative;width:'+fadewidth+'px;height:'+fadeheight+'px;overflow:hidden;"><div id="'+this.canvasbase+'_0" style="position:absolute;width:'+fadewidth+'px;height:'+fadeheight+'px;top:0;left:0;filter:progid:DXImageTransform.Microsoft.alpha(opacity=10);-moz-opacity:10;-khtml-opacity:10;background-color:'+fadebgcolor+'"></div><div id="'+this.canvasbase+'_1" style="position:absolute;width:'+fadewidth+'px;height:'+fadeheight+'px;top:0;left:0;filter:progid:DXImageTransform.Microsoft.alpha(opacity=10);-moz-opacity:10;background-color:'+fadebgcolor+'"></div></div>')
 else
 document.write('<div><img name="defaultslide'+this.slideshowid+'" src="'+this.postimages[0].src+'"></div>')
  
 if (iebrowser&&dom||dom) //if IE5+ or modern browsers such as Firefox
 this.startit()
 else{
 this.curimageindex++
 setInterval("fadearray["+this.slideshowid+"].rotateimage()", this.delay)
 }
 }
 
 function fadepic(obj){
 if (obj.degree<100){
 obj.degree+=10
 if (obj.tempobj.filters&&obj.tempobj.filters[0]){
 if (typeof obj.tempobj.filters[0].opacity=="number") //if IE6+
 obj.tempobj.filters[0].opacity=obj.degree
 else //else if IE5.5-
 obj.tempobj.style.filter="alpha(opacity="+obj.degree+")"
 }
 else if (obj.tempobj.style.MozOpacity)
 obj.tempobj.style.MozOpacity=obj.degree/101
 else if (obj.tempobj.style.KhtmlOpacity)
 obj.tempobj.style.KhtmlOpacity=obj.degree/100
 }
 else{
 clearInterval(fadeclear[obj.slideshowid])
 obj.nextcanvas=(obj.curcanvas==obj.canvasbase+"_0")? obj.canvasbase+"_0" : obj.canvasbase+"_1"
 obj.tempobj=iebrowser? iebrowser[obj.nextcanvas] : document.getElementById(obj.nextcanvas)
 obj.populateslide(obj.tempobj, obj.nextimageindex)
 obj.nextimageindex=(obj.nextimageindex<obj.postimages.length-1)? obj.nextimageindex+1 : 0
 setTimeout("fadearray["+obj.slideshowid+"].rotateimage()", obj.delay)
 }
 }
  
 fadeshow.prototype.populateslide=function(picobj, picindex){
 var slideHTML=""
 var widthFactor=100
 var picWidth = this.postimages[picindex].width
 var picHeight = this.postimages[picindex].height
 if (picWidth > fadeWD)
 {
  widthFactor = (fadeWD / picWidth)
  picWidth = Math.round(picWidth*widthFactor)
  picHeight = Math.round(picHeight*widthFactor)
 }

 if (this.theimages[picindex][1]!="") //if associated link exists for image
 slideHTML='<a href="'+this.theimages[picindex][1]+'" target="'+this.theimages[picindex][2]+'">'
 slideHTML+='<img src="'+this.postimages[picindex].src+'" border="'+this.imageborder+'px" width="'+picWidth+'px" height="'+picHeight+'px">'
 if (this.theimages[picindex][1]!="") //if associated link exists for image
 slideHTML+='</a>'
 picobj.innerHTML=slideHTML
 }
  
  
 fadeshow.prototype.rotateimage=function(){
 if (this.pausecheck==1) //if pause onMouseover enabled, cache object
 var cacheobj=this
 if (this.mouseovercheck==1)
 setTimeout(function(){cacheobj.rotateimage()}, 100)
 else if (iebrowser&&dom||dom){
 this.resetit()
 var crossobj=this.tempobj=iebrowser? iebrowser[this.curcanvas] : document.getElementById(this.curcanvas)
 crossobj.style.zIndex++
 fadeclear[this.slideshowid]=setInterval("fadepic(fadearray["+this.slideshowid+"])",50)
 this.curcanvas=(this.curcanvas==this.canvasbase+"_0")? this.canvasbase+"_1" : this.canvasbase+"_0"
 }
 else{
 var ns4imgobj=document.images['defaultslide'+this.slideshowid]
 ns4imgobj.src=this.postimages[this.curimageindex].src
 }
 this.curimageindex=(this.curimageindex<this.postimages.length-1)? this.curimageindex+1 : 0
 }
  
 fadeshow.prototype.resetit=function(){
 this.degree=10
 var crossobj=iebrowser? iebrowser[this.curcanvas] : document.getElementById(this.curcanvas)
 if (crossobj.filters&&crossobj.filters[0]){
 if (typeof crossobj.filters[0].opacity=="number") //if IE6+
 crossobj.filters(0).opacity=this.degree
 else //else if IE5.5-
 crossobj.style.filter="alpha(opacity="+this.degree+")"
 }
 else if (crossobj.style.MozOpacity)
 crossobj.style.MozOpacity=this.degree/101
 else if (crossobj.style.KhtmlOpacity)
 crossobj.style.KhtmlOpacity=obj.degree/100
 }
  
  
 fadeshow.prototype.startit=function(){
 var crossobj=iebrowser? iebrowser[this.curcanvas] : document.getElementById(this.curcanvas)
 this.populateslide(crossobj, this.curimageindex)
 if (this.pausecheck==1){ //IF SLIDESHOW SHOULD PAUSE ONMOUSEOVER
 var cacheobj=this
 var crossobjcontainer=iebrowser? iebrowser["master"+this.slideshowid] : document.getElementById("master"+this.slideshowid)
 crossobjcontainer.onmouseover=function(){cacheobj.mouseovercheck=1}
 crossobjcontainer.onmouseout=function(){cacheobj.mouseovercheck=0}
 }
 this.rotateimage()
 }
