묻고답하기
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
[새창 위치] 화면 왼쪽 가장위에서 창이 뜨도록 하고싶어요.
2004.05.10 12:08
안녕하세요.
아래거는 새창 뛰우기 소스인데요.
imgWin.moveTo(0,0); <- 소스가 화면 가장 왼쪽 가장 위에서 나오도록 하는 소스인데..
아래 소스의 어느 부분에 넣어야 되는지를 모르겠습니다.
좀 알려주세요.
<script language="JavaScript">
var win1Open = null
function displayImage(picName, windowName, windowWidth, windowHeight){
return window.open(picName,windowName,"toolbar=no,scrollbars=no,resizable=no,width=" + (parseInt(windowWidth)+20) + ",height=" + (parseInt(windowHeight)+15)) }
function winClose(){
if(win1Open != null) win1Open.close() }
function doNothing(){}
</script>
<script language="JavaScript1.1">
function displayImage(picName, windowName, windowWidth, windowHeight){
var winHandle = window.open("" ,windowName,"toolbar=no,scrollbars=no,resizable=no,width=" + windowWidth + ",height=" + windowHeight)
if(winHandle != null){
var htmlString = "<html><head><title>Picture</title></head>"
htmlString += "<body leftmargin=0 topmargin=0 marginwidth=0 marginheight=0>"
htmlString += "<a href=javascript:window.close() onfocus='this.blur()'+ '+ '><img src=" + picName + " border=0 alt=닫기></a>"
htmlString += "</body></html>"
winHandle.document.open()
winHandle.document.write(htmlString)
winHandle.document.close()
}
if(winHandle != null) winHandle.focus()
return winHandle
}
</script>
아래거는 새창 뛰우기 소스인데요.
imgWin.moveTo(0,0); <- 소스가 화면 가장 왼쪽 가장 위에서 나오도록 하는 소스인데..
아래 소스의 어느 부분에 넣어야 되는지를 모르겠습니다.
좀 알려주세요.
<script language="JavaScript">
var win1Open = null
function displayImage(picName, windowName, windowWidth, windowHeight){
return window.open(picName,windowName,"toolbar=no,scrollbars=no,resizable=no,width=" + (parseInt(windowWidth)+20) + ",height=" + (parseInt(windowHeight)+15)) }
function winClose(){
if(win1Open != null) win1Open.close() }
function doNothing(){}
</script>
<script language="JavaScript1.1">
function displayImage(picName, windowName, windowWidth, windowHeight){
var winHandle = window.open("" ,windowName,"toolbar=no,scrollbars=no,resizable=no,width=" + windowWidth + ",height=" + windowHeight)
if(winHandle != null){
var htmlString = "<html><head><title>Picture</title></head>"
htmlString += "<body leftmargin=0 topmargin=0 marginwidth=0 marginheight=0>"
htmlString += "<a href=javascript:window.close() onfocus='this.blur()'+ '+ '><img src=" + picName + " border=0 alt=닫기></a>"
htmlString += "</body></html>"
winHandle.document.open()
winHandle.document.write(htmlString)
winHandle.document.close()
}
if(winHandle != null) winHandle.focus()
return winHandle
}
</script>