function autoresize(){ var extendHeight = 30; var extendWidth = 30; // margin ?? // 1024 x 768 ±âÁØ var maxWidth = 820; var maxHeight = 480; var screenLeft = 204; var screenTop = 258; if( screen.width > 1024 ){ if( window.opener.top.screenLeft == 0 || window.opener.top.screenLeft ) screenLeft = window.opener.top.screenLeft+195; else screenLeft = window.opener.top.pageXOffset + 195; // FF only maxWidth = screen.width - screenLeft; } if( screen.height > 768 ){ if( window.opener.top.screenTop==0 || window.opener.top.screenTop ) screenTop = window.opener.top.screenTop +110; else screenTop = window.opener.top.pageYOffset + 270; // FF only if( navigator.userAgent.indexOf("Safari") != -1 ) screenTop += 110; if( window.opener.top.screenTop==0 || window.opener.top.screenTop ) maxHeight = screen.availHeight - window.screenTop ; // taskbar Å©±â Á¦¿Ü else maxHeight = screen.availHeight - screenTop ; // taskbar Å©±â Á¦¿Ü } // opera´Â window.opener.topÀÇ È­¸é Å©±â¸¦ ³ÑÁö ¾Ê°Ô if( navigator.userAgent.indexOf("Opera") != -1 ) { maxHeight = window.opener.top.document.body.clientHeight;//-150; maxWidth = window.opener.top.document.body.clientWidth; screenTop = 150; } if( window.opener.top.document.body.clientWidth > 1024 ) screenLeft = 195 + ( window.opener.top.document.body.clientWidth - 1024 )/2; // À©µµ¿ì°¡ È­¸éÀ» ³Ñ¾î°¡¸é ¿ÞÂÊÀ¸·Î À̵¿ ½ÃŲ´Ù. if( document.body.scrollWidth > maxWidth ){ maxWidth = Math.min(document.body.scrollWidth+extendWidth,screen.width); screenLeft = screen.width - maxWidth } // ÆË¾÷À» À̵¿ ½Ã۰í, Å©±â¸¦ Á¶Àý ÇÑ´Ù. //window.moveTo( screenLeft, screenTop); if( navigator.userAgent.indexOf("Opera") != -1 ) extendHeight = 10; if( navigator.userAgent.indexOf("Safari") != -1 ) extendHeight = 0; if( navigator.userAgent.indexOf("Firefox") != -1) extendWidth = 10; if( navigator.userAgent.indexOf("Firefox") != -1 ) { window.resizeTo( Math.min((window.innerWidth+window.scrollMaxX+extendWidth),maxWidth), Math.min((document.body.scrollHeight+extendHeight),maxHeight) ); } else { window.resizeTo( Math.min(document.body.scrollWidth+extendWidth,maxWidth), Math.min(document.body.scrollHeight+extendHeight,maxHeight) ); } //alert("client : "+ document.body.clientWidth +":" +document.body.clientHeight ); // All(o) }