/*
UniPop Script for universal popup functionality.
*/

(function UniPop(Width, Height, ViewID, ObjectID, CC) {
	var w = 800, h = 600;
	if (document.all || document.layers) {
		w = screen.availWidth;
		h = screen.availHeight;
	}
	var popW = Width, popH = Height;
	var leftPos = (w-popW)/2, topPos = (h-popH)/2;
	var theURL = "./UniPop.cfm?v=" + ViewID + "&OID=" + ObjectID + "&CC=" + CC;
	newwindow=window.open(theURL, "UniPop", "scrollbars=yes,resizable=yes,width=" + popW + ",height=" + popH + ",top=" + topPos + ",left=" + leftPos);
	if (window.focus) {newwindow.focus()}
});
