// FRAME ELIMINATOR
// Checks to see if the site is being framed, and pulls the site out.
if (window.location!=top.location) {
	top.location = window.location;
}
	 
	 
	 
	 
	 
// OPEN WINDOW FUNCTION
// pulls in customized link, width, height, scrollability
function popUpNew(Page, Width, Height, Scroll) {
window.open(Page,"popUpWindow",'width='+Width+',height='+Height+',toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars='+Scroll+',copyhistory=no,resizable=yes');
  }
// the rest...
// toolbar - icons;  location - URL address bar;  directories - links bar;   status - progress bar at bottom;
// menubar - File, Edit, etc;  copyhistory - retains history list from parent window;  resizable - allows resizing



// FIX N4 CSS ISSUE	
// Netscape 4 has a nasty bug of forgetting an external stylesheet is attached when the browswer is resized
// This script compensates for Netscape's shortsightedness
if (document.layers) {
	origWidth = innerWidth;
	origHeight = innerHeight;
	}

function reloadPage () {
	if (innerWidth != origWidth || innerHeight != origHeight) {
		location.reload();
		}
	}

if (document.layers) onresize = reloadPage;



// SCROLLBAR CHANGES COLOR  
// Makes the color of the scrollbars match the background, if color entered correctly
function changeScrollbarColor(C) {
   if (document.all) {
      document.body.style.scrollbarBaseColor = C;
   }
}

  
// SWAP IMAGE
function swapImage (name, source) {
	var image;
	image = findDOMimage(name);
	image.src = source;
}  

function swapImageDiv (name, source, div) {
	var image = new Image;
	var rollover = new Image;
	layer = findDOM(div);
	image = findDOMimage(name);
	rollover.src = source;
	layer.image.src = rollover.src;
}  
	


//SET NEW Z-INDEX LEVEL
//Change a DIVs Z Level on the page
function setZIndex(objectName, newIndex) {
	var refObject = findDOM(objectName,1);
	refObject.zIndex = newIndex;

}


//CLAMSHELLMENU Script
//Hides and displays something with the block style
function toggleClamShellMenu(objectID, imgName) {
			if (isAll || isID) {
				
				domStyle = findDOM(objectID,1);
				tempImg = findDOMimage(imgName);
				
				if (domStyle.display == 'block') {
					
					 domStyle.display='none';
					 tempImg.src="images/buttonRight.gif";
				} else {
					
					domStyle.display='block';
					tempImg.src = "images/buttonDown.gif";
				
	
				}
			
			}
			else {
				destination = objectID + '.asp';
				self.location = destination;
			}
			return;
}

//SHOWBLOCK Script
//Used in conjunction with clamshellmenu to stop all this silly double-click stuff
function showBlock(objectName, imgName)  {
		if (isAll || isID) {
		img = findDOMimage(imgName);
		obj = findDOM(objectName, 1);
		obj.display = 'block';
		img.src = "images/buttonDown.gif";
		}
}

function showBlock2(objectName)  {
		if (isAll || isID) {
		obj = findDOM(objectName, 1);
		obj.display = 'block';
		}
}


	
// ANTI-SPAM
	function antispam(name,domain) {
    	document.location = "mailto:" + name + "@" + domain;
	}
// -->