baseHref = "/_res/javascripts/AC_OETags.js";
document.write('<script language="javascript" src="' + baseHref + '"></script>');

var nn4 = (document.layers) ? true : false
var ie = (document.all) ? true : false
var dom = (document.getElementById && !document.all) ? true : false

function showHideLayer(layerName) {
	document.getElementById(layerName).style.visibility="hidden";
}

function popFlashVideo (vidSrc,divID,windowTitle,leftPos,topPos) {
	//use create empty div in dom
	var theDiv = document.createElement('div'); 
	theDiv.type = 'html'; 
	document.getElementsByTagName('body')[0].appendChild(theDiv);
	document.getElementsByTagName('body')[0].getElementsByTagName('div')[0].setAttribute('id',divID);
	
	// Globals
	// Major version of Flash required
	var requiredMajorVersion = 7;
	// Minor version of Flash required
	var requiredMinorVersion = 6;
	// Minor version of Flash required
	var requiredRevision = 5;
	
	var hasReqestedVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
	// Check to see if the version meets the requirements for playback
		if (hasReqestedVersion) {
			var URL = vidSrc;
			
				// create flash embed tags
				flashOpenString = '<embed quality="high" id="flash' + divID + '" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"';
				flashCloseString = "/>";
				embedTag = flashOpenString + ' src = "' + vidSrc + '&thisDiv=' + divID + '&thisTitle=' + windowTitle + '" width="330" height="270"' + flashCloseString;
				
				// insert flash tags and give div some atrbs
				document.getElementById(divID).innerHTML = embedTag;
				document.getElementById(divID).style.position="absolute";
				document.getElementById(divID).style.zIndex=5;
				document.getElementById(divID).style.visibility="visible";
				document.getElementById(divID).style.height=270;
				document.getElementById(divID).style.width=305;
				document.getElementById(divID).style.top=topPos;
				document.getElementById(divID).style.left=leftPos;
				//pass layer name to flash movie
				//alert(document.getElementById(["flash" + divID]));
						
			/*
			if(nn4) {	
				path.document.open()
				path.document.write(content) //write content to layer
				path.document.close()
				path.visibility="visible"	//change visibility to visible
			}	else {		
				document.getElementById(divID).innerHTML = content  //write content to layer
				alert()
				path.style.visibility="visible"	//change visibility to visible
			}*/

		} else {  
			// flash is too old or we can't detect the plugin
			var alternateContent = 'To Discover Bellarmine, please download the latest Flash player. It takes just a few seconds for broadband users (a bit longer for dialup) and lets you make the most of this site.';
			alert(alternateContent);  
			// insert non-flash content
		}
}