/* Copyright 2007 - Author: Jonathan Stephan */

function ShowHide(obj)
{
	if (document.getElementById(obj).style.display == 'block')
	{
		document.getElementById(obj).style.display = 'none';
	}
	else
	{
		document.getElementById(obj).style.display = 'block';
	}
}

function ObjectLoad(type, div, obj, width, height, file, version, trans, stream)
{
	if (type == 'flash')
	{
		var opaque, cleared, live, con;
		
		if (trans == 1) {opaque = '<param NAME="wmode" Value="Transparent">'; cleared = ' wmode="transparent"'; } else {opaque = ''; cleared = '';}
		if (stream == 1) {live	= '<param name="swliveconnect" value="true">'; con  = ' swliveconnect="true"';} else {live	= ''; con = '';}
	  
		document.getElementById(div).innerHTML = '<object classid=clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' +
		' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=' + version + '" ' + 
		'width=' + width + ' height=' + height + ' name="' + obj + '" id="' + obj + '">' + opaque + 
		'<param name="movie" value=' + file + '><param name=quality value=high>' + live + 
		'<embed src=' + file + ' ' + cleared + ' quality=high ' +
		'pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" ' +
		'type="application/x-shockwave-flash" width=' + width + ' height=' + height + ' name="' + obj + '" id="' + 
		obj + '" ' + con + '></embed></object>';
	}
	if (type == 'wmv')
	{
		document.getElementById(div).innerHTML = '<object classid=clsid:6BF52A52-394A-11d3-B153-00C04F79FAA6 id=' + obj + 
		' width=' + width + ' height=' + height +'><param name="URL" value=' + file + '><param name="autoStart" value=-1/>';
	}
}