

function writeFlash(divId, movieSrc, height, width , flashEnabled, altImageSource, altText, controlId)
{
	var div = document.getElementById(divId);
	var divCont = "";
	if(flashEnabled)
	{
		divCont += '<OBJECT id="' + controlId + '" codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0"	height="' + height + '" width="' + width + '" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" VIEWASTEXT>';
		divCont += '	<PARAM NAME="Movie" VALUE="' + movieSrc + '">';
		divCont += '	<PARAM NAME="Quality" VALUE="High">';
		divCont += '	<PARAM NAME="Src" VALUE="' + movieSrc + '">';
		divCont += '	<PARAM NAME="WMode" VALUE="transparent">';
		divCont += '	<embed src="' + movieSrc + '" wmode=transparent name="flashAnimation" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="' + width + '" height="' + height + '"> </embed>';
		divCont += '</OBJECT>';				
	}
	else
	{
		if(altImageSource != "" && altImageSource != null) divCont += '<img src="' + altImageSource + '" width="' + width + '" height="' + height + '" alt="' + altText + '">';
	}	
	div.innerHTML = divCont;
}