//common javascript methods for hp
var d = document;
//Pop Up in a new window
/*<a href="javascript:popupWindow('http://www.carthaycenterschool.org.com','width=570, height=550, scrollbars=yes, resizable=yes, screenX=200, screenX=0, left=200, top=0');"></a>*/
function popupWindow(url,specs) {
	/* Custom Browser Attributes:
	width	number
	height	number
	* the default to these yes|no ones, is no *
	directories	yes | no (or 1 | 0)
	location	yes | no (or 1 | 0)
	menubar		yes | no (or 1 | 0)
	resizable	yes | no (or 1 | 0)
	scrollbars	yes | no (or 1 | 0)
	status		yes | no (or 1 | 0)
	toolbar		yes | no (or 1 | 0)
	*browser specific*
	screenX (NN4+)	number
	screenY (NN4+)	number
	left (IE4+)		number
	top	(IE4+)		number
	fullscreen (IE4+)	yes | no (or 1 | 0)
	*/
	window.open(url, "_blank", specs);
}
//SECTION ID'S INCLUDE: ?section=  mapHome, mapOff, mapLower, mapUpper, mapQuidditch...


//For pop up windows going elsewhere
//get browser
var browser = navigator.appName;
//Open tout_url in mainwindow and close the popup
function gotoTOUT(tout_url, specs) {
//Pop-Up Window
//IE version
	if (browser == "Microsoft Internet Explorer"){
		var newWindow = window.open(tout_url, "mainwindow");
		self.close();
//Netscape (and any other browser type) version
	} else {
//If the parent window has been closed, open a new window
		if (window.opener == null){
			var newWindow = window.open(tout_url);
			self.close();
//If the parent window is still there, redirect it
		} else {
			var newWindow = window.opener.location.replace(tout_url);
			self.close();
		}
	}
}

//Functions 
function launchSomething(){
     window.open("page", "name","toolbar=0,scrollbars=0,menubar=0,resizable=1,width=570,height=550, screenX=200, screenX=0, left=200, top=0");
}

//Image Rollover
function over(imgName, img_src) {
	d[imgName].src=img_src;
}
function out(imgName, img_src) {
	d[imgName].src=img_src;
}

//Image Rollover for layers
function layerOver(layerName, imgName, img_src) {
	this.layer=document.layers?document[layerName].document[imgName].src=img_src:document[imgName].src=img_src;
	}
function layerOut(layerName, imgName, img_src) {
	this.layer=document.layers?document[layerName].document[imgName].src=img_src:document[imgName].src=img_src;
	}
	

//  End -->


