<!--
/***************
JSCRIPT.JS

Contains the global javascripts
***************/

// OPENS FORM FOR ADDING/EDITING STAFF
function openForm(URL) {
	window.open(URL, "FormWin", "width=450,height=500,status,scrollbars");
}

// CONFIRM AN ACTION BEFORE REDIRECTING
function confirmAction(question, redirectTo) {
	if (confirm(question)) document.location = redirectTo;
}

// OPEN IMAGE WINDOW
function openImageWin(ImageFilePath, w, h) {
	winW = (w + 30);
	winH = (h + 40);
	
	window.open(ImageFilePath, "ImageWin", "width=" + winW + ",height=" + winH);
}

// CONFIRMS ACTION THEN SUBMITS A FORM RATHER THAN REDIRECTS TO ANOTHER LOCATION
function confirmActionSubmitForm(question, formName, formActQueryStr) {
	if (confirm(question)) {
		document[formName].action = formActQueryStr;
		document[formName].submit();
	}
}
// -->