이미지클릭하면열리는이미지크기조정문제입니다. 정보
이미지클릭하면열리는이미지크기조정문제입니다.본문
안녕하세요.
gbview.skin.php에있는 자바스크립트부분입니다.
<SCRIPT LANGUAGE='JavaScript'>
<!--
var win= null;
function center_window(img, w, h)
{
var winl = (screen.width-w)/2;
var wint = (screen.height-h)/3;
var settings ='height='+h+',';
settings +='width='+w+',';
settings +='top='+wint+',';
settings +='left='+winl+',';
settings +='scrollbars=yes,';
settings +='resizable=no,';
settings +='status=no';
win=window.open("","newWindow",settings);
win.document.open();
win.document.write ("<html><head><title>이미지 보기</title></head>");
win.document.write ("<body leftmargin=0 topmargin=0>");
win.document.write ("<img src='"+img+"' border=0 onclick='window.close();' style='cursor:hand' title='클릭하면 닫혀요'>");
win.document.write ("</body></html>");
win.document.close();
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
//-->
</SCRIPT>
여기에서
이미지클릭하면 고정된크기로 열리게 하고싶은데 어떻게 하는지를 몰라서요.
원하는건 클릭하면 가로400*400에 열리게 할수없나요.
가로세로비율까지맞춰주면 더욱좋겠구요.
안되면 스크롤바있어도 괞잖은데 현재는 전체창으로 뜨네요.
gbview.skin.php에있는 자바스크립트부분입니다.
<SCRIPT LANGUAGE='JavaScript'>
<!--
var win= null;
function center_window(img, w, h)
{
var winl = (screen.width-w)/2;
var wint = (screen.height-h)/3;
var settings ='height='+h+',';
settings +='width='+w+',';
settings +='top='+wint+',';
settings +='left='+winl+',';
settings +='scrollbars=yes,';
settings +='resizable=no,';
settings +='status=no';
win=window.open("","newWindow",settings);
win.document.open();
win.document.write ("<html><head><title>이미지 보기</title></head>");
win.document.write ("<body leftmargin=0 topmargin=0>");
win.document.write ("<img src='"+img+"' border=0 onclick='window.close();' style='cursor:hand' title='클릭하면 닫혀요'>");
win.document.write ("</body></html>");
win.document.close();
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
//-->
</SCRIPT>
여기에서
이미지클릭하면 고정된크기로 열리게 하고싶은데 어떻게 하는지를 몰라서요.
원하는건 클릭하면 가로400*400에 열리게 할수없나요.
가로세로비율까지맞춰주면 더욱좋겠구요.
안되면 스크롤바있어도 괞잖은데 현재는 전체창으로 뜨네요.
댓글 전체