function embedResource(asset, height, width, color) 
{
	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" ');
	document.write('height="' + height + '"');
	document.write('width="' + width + '">');
	document.write('<param name="src" value="' + asset + '">');
	document.write('<param name="allowScriptAccess" value="sameDomain" />');
	document.write('<param name="align" value="middle">');
	document.write('<param name="quality" value="high">');
	document.write('<param name="bgcolor" value="' + color + '">');
	document.write( '<embed ' );
	document.write( '  src="' + asset + '" ' );
	document.write( '  name="' + name + '"' );
	document.write( '  height="' + height + '" ' );
	document.write( '  width="' + width + '" ' );
	document.write( '  align="middle" ' );
	document.write( '  quality="high" ' );
	document.write( '  allowScriptAccess="sameDomain" ' );
	document.write( '  scale="aspect" ' );
	document.write( '  pluginspage="http://www.macromedia.com/go/getflashplayer" ' );
	document.write( '  bgcolor="' + color + '" ' );
	document.write( '  type="application/x-shockwave-flash">' );
	document.write( '</embed>' );
	document.write('</object>');
}

function openMovie(URL)
{
	window.open("MovieResourceLauncher.htm?asset=" + URL + "&footer=","More_ELA_Live_Video","toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,scrolling=yes,resizable=yes,width=800,height=600,left=0,top=0");
}

function openFull(URL)
{
	window.open("MovieResourceLauncher.htm?asset=" + URL + "&footer=","More_ELA_Live_Video","toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,scrolling=yes,resizable=yes,width=800,height=600,left=0,top=0");
}

function OpenFooterAsset(URL)
{
	window.open(URL,"More_ELA_Live_Information","toolbar=no,location=yes,directories=no,status=no,menubar=yes,scrollbars=yes,scrolling=yes,resizable=yes,width=750,height=550,left=0,top=0");
}

function embedQuickTime()
{
	var movie = parent.location.search.substring(7, parent.location.search.indexOf("footer") - parent.location.search.indexOf("asset")).replace("movieLauncher.htm?movie=","");
	
	if (movie == "?movie=") movie = parent.location.search.substring(7, parent.location.search.length).replace("&launch=true","");
	
	movie = "StreamedMovie.mov?Cdn.Rewrite=1&Cdn.RewritePath=/english_language_arts_10_20_30/" + movie.replace("smil/","").replace(".smil",".mov");
	
	document.write("<object classid='clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B' width='100%' height='100%' codebase='http://www.apple.com/qtactivex/qtplugin.cab'>");
		document.write("<param name='src' value='" + movie +"' />");
		document.write("<param name='controller' value='true' />");
		document.write("<param name='autoplay' value='true' />");
		document.write("<param name='enablejavascript' value='true' />");
		document.write("<param name='scale' value='aspect' />");
		document.write("<param name='kioskmode' value='true' />");
		document.write("<param name='bgcolor' value='#000000' />");
		
		document.write("<embed ");
			document.write("src='" + movie + "'");
			document.write("width='100%'");
			document.write("height='100%'");
			document.write("autoplay='true'");
			document.write("scale='aspect'");
			document.write("kioskmode='true'");
			document.write("bgcolor='#000000'");
			document.write("type='video/quicktime'");
			document.write("pluginspage='http://www.apple.com/quicktime/download/'");
			document.write("enablejavascript='true'");
			document.write("controller='true'");
		document.write("></embed>");
	document.write("</object>");
}
