// JavaScript Document
//生成SWF调用函数
function WirteFlashBlock(strURL,nWidth,nHeight,strBkColor,strID,strAlignMode,strQuality,strFlashVars){
	var embedTxt;
	embedTxt = "<embed";
	if (strURL==null){
		return;
	}
	embedTxt += ' src="'+strURL+'"';
	document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0"');
	if (nHeight){
		document.write(' height="'+nHeight+'"');
		embedTxt += ' height="'+nHeight+'"';
	}
	if (nWidth){
		document.write(' width="'+nWidth+'"');
		embedTxt += ' width="'+nWidth+'"';
	}
	if (strID){
		document.write(' id="'+strID+'"');
		embedTxt += ' name="'+strID+'"';
	}
	if (strAlignMode){
		document.write(' align="'+strAlignMode+'"');
		embedTxt += ' align="'+strAlignMode+'"';
	} 
	document.write('>');
	document.writeln('<param name="menu" value="false">');
	document.writeln('<param name="WMode" value="Transparent">');
	document.writeln('<param name="WMode" value="opaque">'); 
	embedTxt += ' menu="false"';
	document.writeln('<param name="allowScriptAccess" value="always" />');
	embedTxt += ' allowScriptAccess="always"';
	if (strFlashVars){
		document.writeln('<PARAM NAME=FlashVars VALUE="'+strFlashVars+'">');
		embedTxt += ' FlashVars="'+strFlashVars+'"';
	} 
	document.writeln('<param name="movie" value="'+strURL+'" />');
	if (strQuality){
		document.writeln('<param name="quality" value="'+strQuality+'" />');
		embedTxt += ' quality="'+strQuality+'"';
	}else{
		document.writeln('<param name="quality" value="High" />');
		embedTxt += ' quality="High"';
	}
	if (strBkColor){
		document.writeln('<param name="bgcolor" value="'+strBkColor+'" />');
		embedTxt += ' bgcolor="'+strBkColor+'"';
	}
	embedTxt += ' type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash"  swLiveConnect="true" ></embed>';
	document.writeln(embedTxt);
	document.writeln('</object>');
}