/* function or opening a popup window */

function createWindow(cUrl,cName,cFeatures) {
	var xWin = window.open(cUrl,cName,cFeatures);
	xWin.focus();
}

function shutwin() {
	var xWin = window.close();
}



function noSpam(user,domain) {
	locationstring = "mailto:" + user + "@" + domain;
	window.location = locationstring;
}

function changeImages() {
	if (document.images) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

function preloadImages() {
	document.preload = new Array();
	if (document.images) {
		for (var i = 0; i < preloadImages.arguments.length; i++) {
			document.preload[i] = new Image();
			document.preload[i].src = preloadImages.arguments[i];
		}
	}
}

// toggle visibility 
function toggle( targetId ){
  if (document.getElementById){
		target = document.getElementById( targetId );
		if (target.style.display == "none"){
			target.style.display = "";
		} else {
			target.style.display = "none";
		}
	}
}

// hide visibility 
function hideem( targetId ){
  if (document.getElementById){
		target = document.getElementById( targetId );
		if (target.style.display == ""){
			target.style.display = "none";
		}
	}
}