g

view.skin.php에서 파일 새창띄우기 질문 드립니다...

ex.gif
토마토님의 자동차 스킨을 사용하는데......
 
스샷...① 부분을 클릭하면 이미지 팝업창 띄우는 방법 아시는분은 알려주세요..
 
미련하게 다른 보드의 방법을 사용했다는...ㅡㅡ;;;
 
 
파일불러오는 소스..
 
<table cellpadding="3" cellspacing="1" bgcolor="cccccc">
                                <tr>
                                  <td bgcolor="ffffff"><? if ($view[file][0][view])  {?>
                                      <img src="<?=$image[0]?>" name=gallery_img width="210" height="180" border=0 value=0>  ←   (해당부분)
                                      <? } else {?>
                                      <img src="<?=$board_skin_path?>/img/noimg.gif" border=0 value=0>
                                      <? } ?></td>
                                </tr>
                              </table>
                              <table align="center">
                                <tr>
                                  <td><?=$view[file][0][content]?></td>
                                </tr>
                              </table>
                              <table width="100%" cellpadding="5" >
                                <tr>
                                  <td align="center"><? if ($view[file][0][file]) {?>
                                      <a href=# <? echo "onClick=\"chgImg( '".$image[0]."','".$image[0]."','".ereg_replace("(\r\n|\n|\r)", "<br>", strip_tags($content) )."' );\"" ?>> <img src="<?=$board_skin_path?>/img/car_p_1.gif" align="absmiddle" border="0"></a>
                                      <? }?>
                                      <? if ($view[file][1][file]) {?>
                                      <a href=# <? echo "onClick=\"chgImg( '".$image[1]."','".$image[1]."','".ereg_replace("(\r\n|\n|\r)", "<br>", strip_tags($content) )."' );\"" ?>> <img src="<?=$board_skin_path?>/img/car_p_2.gif" align="absmiddle" border="0"></a>
                                      <? }?>
                                      <? if ($view[file][2][file]) {?>
                                      <a href=# <? echo "onClick=\"chgImg( '".$image[2]."','".$image[2]."','".ereg_replace("(\r\n|\n|\r)", "<br>", strip_tags($content) )."' );\"" ?>> <img src="<?=$board_skin_path?>/img/car_p_3.gif" align="absmiddle" border="0"></a>
                                      <? }?>
                                      <? if ($view[file][3][file]) {?>
                                      <a href=# <? echo "onClick=\"chgImg( '".$image[3]."','".$image[3]."','".ereg_replace("(\r\n|\n|\r)", "<br>", strip_tags($content) )."' );\"" ?>> <img src="<?=$board_skin_path?>/img/car_p_4.gif" align="absmiddle" border="0"></a>
                                      <? }?>
                                      <? if ($view[file][4][file]) {?>
                                      <a href=# <? echo "onClick=\"chgImg( '".$image[4]."','".$image[4]."','".ereg_replace("(\r\n|\n|\r)", "<br>", strip_tags($content) )."' );\"" ?>> <img src="<?=$board_skin_path?>/img/car_p_5.gif" align="absmiddle" border="0"></a>
                                      <? }?>
                                  </td>
                                </tr>
                            </table>

첨부파일

ex.gif (2.5 KB)
0회 2006-06-09 22:51

댓글 1개

아래 스크립트를 사용하시면 .... 쬐끔이나마...

function resize_image()
{
var target = document.getElementsByName('target_resize_image[]');
var image_width = parseInt('<?=$board[bo_image_width]?>');
var image_height = 0;

for(i=0; i<target.length; i++) {
// 원래 사이즈를 저장해 놓는다
target[i].tmp_width = target[i].width;
target[i].tmp_height = target[i].height;
// 이미지 폭이 테이블 폭보다 크다면 테이블폭에 맞춘다
if(target[i].width > image_width) {
image_height = parseFloat(target[i].width / target[i].height)
target[i].width = image_width;
target[i].height = parseInt(image_width / image_height);
}
}
}

window.onload = resize_image;
댓글을 작성하시려면 로그인이 필요합니다.

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기 기존 게시물은 열람만 가능합니다.

+
제목 글쓴이 날짜 조회
06-06-10 조회 1,389
06-06-10 조회 1,610
06-06-10 조회 1,424
06-06-10 조회 1,615
06-06-09 조회 1,204
06-06-09 조회 1,735
06-06-09 조회 1,613
06-06-09 조회 1,614
06-06-09 조회 1,548
06-06-09 조회 1,260
06-06-09 조회 1,628
06-06-09 조회 1,052
06-06-09 조회 1,053
06-06-09 조회 2,001
06-06-09 조회 1,436
06-06-09 조회 1,902
06-06-09 조회 1,543
06-06-09 조회 1,700
06-06-09 조회 1,727
06-06-09 조회 1,637