
var objtxt="";
var nscrpt="";

function buildjs()
{
	var jstut="";
	jstut="<script src=\""+document.objgen.T4.value+".js\" type=\"text/javascript\"></script>";
	return jstut;
}
function buildjsfile(nofswf)
{
	var jstut2="";
	jstut2=jstut2+'function '+document.objgen.T4.value+'(nofswf,wofswf,hofswf,nofxml,bgcm)\n';
	jstut2=jstut2+'{';
	jstut2=jstut2+'	var wstr="";';
	jstut2=jstut2+'	wstr=\'<OBJECT classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" WIDTH="\'+wofswf+\'" HEIGHT="\'+hofswf+\'" id="\'+nofxml+\'" ALIGN=""> <PARAM NAME=movie VALUE="\'+nofswf+\'"> <PARAM NAME=FlashVars VALUE="xml_name=\'+nofxml+\'.xml"> <PARAM NAME=menu VALUE=false> <PARAM NAME=quality VALUE=high> <PARAM NAME=scale VALUE=noscale> <PARAM NAME=salign VALUE=LT> <PARAM NAME=wmode VALUE=opaque> <PARAM NAME=bgcolor VALUE="\'+bgcm+\'"> <EMBED src="\'+nofswf+\'" FlashVars="xml_name=\'+nofxml+\'.xml" menu=false quality=high scale=noscale salign=LT wmode=opaque bgcolor="\'+bgcm+\'"  WIDTH="\'+wofswf+\'" HEIGHT="\'+hofswf+\'" NAME="\'+nofxml+\'" ALIGN="" TYPE="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></EMBED></OBJECT>\';';
	nscrpt='<noscript><OBJECT classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" WIDTH="'+document.objgen.T1.value+'" HEIGHT="'+document.objgen.T2.value+'" id="'+document.objgen.T4.value+'" ALIGN=""> <PARAM NAME=movie VALUE="'+nofswf+'"> <PARAM NAME=FlashVars VALUE="xml_name='+document.objgen.T4.value+'.xml"> <PARAM NAME=menu VALUE=false> <PARAM NAME=quality VALUE=high> <PARAM NAME=scale VALUE=noscale> <PARAM NAME=salign VALUE=LT> <PARAM NAME=wmode VALUE=opaque> <PARAM NAME=bgcolor VALUE="'+document.objgen.T3.value+'">';
	nscrpt=nscrpt+'<EMBED src="'+nofswf+'" FlashVars="xml_name='+document.objgen.T4.value+'.xml" menu=false quality=high scale=noscale salign=LT wmode=opaque bgcolor="'+document.objgen.T3.value+'"  WIDTH="'+document.objgen.T1.value+'" HEIGHT="'+document.objgen.T2.value+'" NAME="'+document.objgen.T4.value+'" ALIGN="" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED></OBJECT></noscript>';
	jstut2=jstut2+'	document.write(wstr);';
	jstut2=jstut2+'}';
	return jstut2;
}


function objrefresh(nofswf)
{
	objtxt='<script src="'+document.objgen.T4.value+'.js" type="text/javascript"></script>';
	objtxt=objtxt+'<script type="text/javascript">'+document.objgen.T4.value+'("'+nofswf+'",'+document.objgen.T1.value+','+document.objgen.T2.value+',"'+document.objgen.T4.value+'","#'+document.objgen.T3.value+'");</script>';
	document.objgen.JS1.value=buildjsfile(nofswf);
	document.objgen.S1.value=""+objtxt+nscrpt;
	step4divobj=document.getElementById("step4div");
	step4divobj.innerHTML="Create "+document.objgen.T4.value+".js file then copy the below into it.";
}

function objcopy()
{
	document.objgen.S1.focus();
	document.objgen.S1.select();
}
function objcopy2()
{
	document.objgen.JS1.focus();
	document.objgen.JS1.select();
}	

