썸네일 클릭시 새창으로 이미지를 뜨게 하고 싶습니다. 정보
썸네일 클릭시 새창으로 이미지를 뜨게 하고 싶습니다.본문
일반 웹진형태의 게시판을 수정중에 있습니다. 이미지 나오고 제목내용이런식으루요.
list.skin.php에서 썸네일을 클릭하면 이미지가 새창으로 떴으면 좋겠습니다.
경로를 어떻게 적어야 되는지 알려주시면 감사드리겠습니다.^^
아래처럼 그냥 해봤는데 안되네요.^^
<td>
<a href=javascript:// onClick="window.open('<?=$img?>', '', 'scrollbars=no,resizeable=yes,toolbar=no,status=no,top=100,left=100,width=400,height=300');" title=''>
<img src='<?=$thum?>' alt='' width="120" height="90" border=0 ></a>
</td>
list.skin.php에서 썸네일을 클릭하면 이미지가 새창으로 떴으면 좋겠습니다.
경로를 어떻게 적어야 되는지 알려주시면 감사드리겠습니다.^^
아래처럼 그냥 해봤는데 안되네요.^^
<td>
<a href=javascript:// onClick="window.open('<?=$img?>', '', 'scrollbars=no,resizeable=yes,toolbar=no,status=no,top=100,left=100,width=400,height=300');" title=''>
<img src='<?=$thum?>' alt='' width="120" height="90" border=0 ></a>
</td>
댓글 전체
방법1
<td>
<a href="window.open('<?=$img?>' target=_blank>
<img src='<?=$thum?>' alt='' width="120" height="90" border=0 ></a>
</td>
방법2
<td>
<a href="javascript:open_win('<?=$img?>');">
<img src='<?=$thum?>' alt='' width="120" height="90" border=0 ></a>
</td>
<script>
function open_win(img){
window.open(img, '', 'scrollbars=no,resizeable=yes,toolbar=no,status=no,top=100,left=100,width=400,height=300');"
}
</script>
<td>
<a href="window.open('<?=$img?>' target=_blank>
<img src='<?=$thum?>' alt='' width="120" height="90" border=0 ></a>
</td>
방법2
<td>
<a href="javascript:open_win('<?=$img?>');">
<img src='<?=$thum?>' alt='' width="120" height="90" border=0 ></a>
</td>
<script>
function open_win(img){
window.open(img, '', 'scrollbars=no,resizeable=yes,toolbar=no,status=no,top=100,left=100,width=400,height=300');"
}
</script>