function thisPopup(URL, left, top, width, height, scrollbars) {
	var standardSetting = 'toolbar=0, location=0, directories=0, status=0, scrollbars=' + scrollbars;
	var customSetting = 'menubar=0, resizable=1, width=' + width + ', height=' + height;
	var positioning = 'left=' + left + ', top =' + top;
	// create window
	closePopup();
	oxl_win = window.open(URL, 'oxl', + '\'' + standardSetting + ', ' + customSetting + ', ' + positioning + '\'');
	oxl_win.focus();
}


function closePopup() {
	if (window.oxl_win) {
		window.oxl_win.close();
	}
}



// pop up to define which shopping list item is placed in
function zoomImage(URL, width, height, scrollbars) {
	var left = 100;
	var top = 50;
	var scrollbars = scrollbars;
	thisPopup(URL, left, top, width, height, scrollbars);
}


function clrRow(src, newColor) {
	src.bgColor = newColor;
}

function borderCell(src, flag) {
	if (flag) {
		src.style.backgroundColor = "#4B4B4B";
	} else {
		src.style.backgroundColor = "#666666";
	}
}

function addComment() {
	thisForm = document.forms["troubleTicketcomment"];
	comment = prompt("add a comment to this trouble ticket", "");
	thisForm.elements["comment"].value = comment;
	if (comment) {
		thisForm.submit();
	}
}
