//copyright 2004 Univeristy of Texas System Administration TeleCampus
//no use restrictions for components of University of Texas System

//-----------------------------------------
//------------- PRIVATE -------------------
//-----------------------------------------

//handling function for IE 6.04 embedded content workaround

function writeEmbdObj(objArray,prmArray,embArray,appArray){

if (writeEmbdObj.arguments.length < 4){
alert("We apologize for the inconvenience, but the JavaScript required to display a particular piece of content on this page is missing one or more arguments.  \nPlease contact Technical Support (Embanet) and ask them to report this issue to the TeleCampus.  You will need to provide the course you are working in and the page on which you are experiencing this problem.") 
}

//creates the opening object tag code if the objectArray exists
if (objArray && objArray != null){
	document.write("<object ");
    for ( anItem in objArray ){
    document.write(anItem + "=\""+ objArray[anItem]+"\" ");
    }
   document.write("/>\n");
}


//creates the opening applet tag code if the appletArray exists
if (appArray && appArray != null){
	document.write("<applet ");
	for ( anItem in appArray ){
	document.write(anItem + "=\""+ appArray[anItem]+"\" ");
	}
	document.write("/>\n");
}


//creates the object parameter code if the paramArray exists
if (prmArray && prmArray != null){
   for ( anItem in prmArray ){
   document.write("<param name=\""+ anItem + "\" value=\""+ prmArray[anItem]+"\" />\n");
   }
}


//creates the embed code if the embedArray Object exists
if (embArray && embArray != null){
   document.write("<embed ");
   for ( anItem in embArray ){
    document.write(anItem + "=\""+ embArray[anItem]+"\" ");
   }


//closes the embed tag  
   document.write("/>\n");
}


//creates the closing object tag if the objectArray exists
if (objArray){
   document.write("</object>");
}


//creates the closing applet tag if the appletArray exists
if (appArray){
	document.write("</applet>");
}

//end function
}