//Clear out search input box when user selects it
function doClear(theText) {if (theText.value == theText.defaultValue) {theText.value = ""}	 }
// END

//Writes the current year in the copyright statement
COPYRIGHT = "";
function writeCopyright(){
	document.write(COPYRIGHT, new Date().getFullYear());
}
// END

//Writes the breadcrumb trail to page
function breadcrumbs(defaultPage){
  sURL = new String;
  bits = new Object;
  dp = new String;
  var dp = defaultPage;
  var escapeChar = "_";
  var x = 0;
  var stop = 0;
  var output = "<a href='/'>Home</a> > ";
  
  if (dp == null){
	  dp = "Default";
  }
  
  sURL = location.href;
  /*sURL = sURL.slice(7,sURL.length);*/
  chunkStart = sURL.toUpperCase().indexOf("HTML/");
  sURL = sURL.slice(chunkStart+5,sURL.length)
  while(!stop){
    chunkStart = sURL.indexOf("/");
    if (chunkStart != -1){
      bits[x] = sURL.slice(0,chunkStart)
      sURL = sURL.slice(chunkStart+1,sURL.length);
    }else{
      stop = 1;
    }
    x++;
  }
  for(var i in bits){
    output += "<a href=\"";
    for(y=1;y<x-i;y++){
      output += "../";
    }
    output += bits[i] + "/" + dp + ".htm\">" + bits[i].replace(/_/g," ") + "</a>  >  ";
  }
  document.write(output + document.title);
}
// END

// Navigation configuration
$(document).ready(function() { 
	$('ul.sf-menu').superfish({ 
		delay:       800,                            	// delay on mouseout, 1000 = 1 second 
		animation:   {opacity:'show',height:'show'},  	// fade-in and slide-down animation 
		speed:       'fast',                          	// faster animation speed 
		autoArrows:  false,                           	// disable generation of arrow mark-up 
		dropShadows: false,                            	// disable drop shadows
		disableHI:   false              				// set to true to disable hoverIntent detection  
	});
	
	$('#ShowSiteMap').click(function () {
		$('#SiteMapWrapper').slideToggle("slow");
	});
	
	$('#SiteMapWrapper').hide();
	
	$("table.zebra tr:nth-child(even)").addClass("odd");//Add zebra stripping when you add class "Zebra" to a table
	
}); 
// END
