// JavaScript Document

/****** ChamaSWF ******
Carrega um arquivo SWF no código sem que o IE o bloqueie.
Passar os paramentros:
	(path = caminho do arquivo)
	(width = largura)
	(height = altura)
	(wmode = passar o  parametro "transparent" caso o swf tenha que ficar transparente, esse paramentro não é obrigatório*/

function ChamaSWF ( path , width , height , wmode )
{
	document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="'+width+'" height="'+height+'">');
	document.write('<param name="allowScriptAccess" value="sameDomain" />');
	document.write('<param name="movie" value="'+path+'">');
	document.write('<param name="quality" value="high">');
	document.write('<param name="wmode" value="'+wmode+'" />');
	document.write('<embed src="'+path+'" width="'+width+'" height="'+height+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" wmode="'+wmode+'"></embed>');
	document.write('</object>');
}

<!-- Script para abrir popups dinamicamente-->

function getObj(id){
	if(document.getElementById){
		//NE
		return document.getElementById(id);
	}else{
		if (document.all) {
			//IE5+
			return document.all(id);	
		}else{
			//IE5-
			return document(id);	
		}
		
	}
}

function resizeWindowByImage(ImageId){
	var myImage = getObj(ImageId);
	window.resizeTo(myImage.width+25, myImage.height+50);
}
