Alguien sabe de algun script para hacer que una ventana popup se ajuste automáticamente al contenido del documento.????
 
he estado probando con este script  pero n o jala chido   
Código:
 var isNN,isIE;
if (parseInt(navigator.appVersion.charAt(0))>=4){
	isNN=(navigator.appName=="Netscape")?1:0;
	isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;
}
function AutoSize(){
	if (isIE){
		width=100-(document.body.clientWidth-document.width);
		height=100-(document.body.clientHeight-document.height);
		window.resizeTo(width,height);
		window.moveTo((screen.width-width)/2,(screen.height-height)/2);
	}
	if (isNN){
		window.moveTo((screen.width-(document.width))/2,(screen.height-(document.height))/2)
		window.innerWidth=document.width;
		window.innerHeight=document.height;
	}
}
window.onload = AutoSize();
  He estado intentandolo pero nomas no me sale.