function over(){
	for(var i=0; i<arguments.length;i++){
		document[arguments[i]].src = "/i/but/" +arguments[i]+"_over.gif";
	}
}

function out(){
	for(var i=0; i<arguments.length;i++){
		document[arguments[i]].src = "/i/but/" +arguments[i]+"_out.gif";
	}
}

function setClearIfFirst(which,what){
	if(which.value == what){
		which.value="";
	}
}

function checkForm(which){
	errorMsg = "Your form is incomplete:\n- - - - - - - - - - - - - - - - - - \n";
	if(which == "frmContact"){
		if((document[which].yourName.value=="enter your name") || (document[which].yourName.value=="")){
			errorMsg += "Please enter your name\n";
			document[which].yourName.id = "textFocus";
		} else {
			document[which].yourName.id = "text";
		}
		if((document[which].yourEmail.value=="enter your email") || (document[which].yourEmail.value=="")){
			errorMsg += "Please enter your email address\n";
			document[which].yourEmail.id = "textFocus";
		} else {
			document[which].yourEmail.id = "text";
		}
		if((document[which].yourComments.value=="enter your comments") || (document[which].yourComments.value=="")){
			errorMsg += "Please enter your Comments\n";
			document[which].yourComments.id = "textareaFocus";
		} else {
			document[which].yourComments.id = "textarea";
		}
	}
	if(errorMsg == "Your form is incomplete:\n- - - - - - - - - - - - - - - - - - \n"){
		document[which].submit();
	} else {
		alert(errorMsg);
	}
}
function playground(page,xheight,xwidth){
	var path="games/" + page + "/index.html";
	var popupvars = "height=" + xheight + ",width=" + xwidth + ",top=40,left=40,status=no,scrollbars=no,toolbar=no,menubar=no,location=no,resize=no";
	window.open(path,page,popupvars);
}
function elseWhere(path,xheight,xwidth){
	var popupvars = "height=" + xheight + ",width=" + xwidth + ",top=40,left=40,status=no,scrollbars=no,toolbar=no,menubar=no,location=no,resize=no";
	window.open(path,'DegeneratePopup',popupvars);
}
