독도 광고 모금 캠페인


시간날때 공부해야 겠네요.
많은 도움이 될듯 합니다.

http://openframework.or.kr/framework_reference/prototype_js/1.4.0/prototype.js.html#DollarFunction

http://www.prototypejs.org/download
이올린에 북마크하기(0) 이올린에 추천하기(0)

'JavaSCript' 카테고리의 다른 글

화면상의 객체 위치,크기  (0) 2008/04/16
prototype.js 를 위한 개발자 노트  (1) 2008/04/16
자바스크립트의 특징  (1) 2008/04/02
@cc_on  (0) 2008/03/24
레이어 드래그 + 투명효과  (2) 2008/03/24
자바스크립트 에러 출력방지  (0) 2008/03/13
Posted by 하로기
TAG ,

트랙백 주소 :: http://harogipro.tistory.com/trackback/191 관련글 쓰기

댓글을 달아 주세요

  1. 정숙연 2008/05/23 16:12  댓글주소  수정/삭제  댓글쓰기

    <?
    if($arr[detailimg2] != "none";){
    @$imginfo = getImageSize("{$DOCUMENT_ROOT}/data/goodimg/".$arr[detailimg2]);
    //echo $imginfo."<br>";

    if(gettype($imginfo) == "array";){
    //echo $imginfo[0]."<br>" ; // 가로크기
    //echo $imginfo[1]."<br>" ; // 세로크기
    //echo $imginfo[2]."<br>" ; // gif일 때 1, jpg일때 2, png일때 3
    //echo $imginfo[3] ; // width="500" height="496"
    $max_len=600;//여기에 범위를 잡아주면 가로 세로 비율이 깨어지지 않는 이미지가 됩니다.
    $width=$imginfo[0];
    $height=$imginfo[1];
    if($width>$height){
    if($width>$max_len){
    $img_width=$max_len;
    }else{
    $img_width=$width;
    }
    $img_height=$height*$img_width/$width;
    }else{
    if($height>$max_len){
    $img_height=$max_len;
    }else{
    $img_height=$height;
    }
    $img_width=$width*$img_height/$height;
    }

    if($imginfo[1]>$max_len || $imginfo[0]>$max_len){
    ?>
    <img src="../../data/goodimg/<?=$arr[detailimg]?>" width="<?=$img_width?>" height="<?=$img_height?>" border=0>
    <? }else{?>
    <img src="../../data/goodimg/<?=$arr[detailimg]?>" <?=$imginfo[3]?> border=0>
    <?
    }
    }
    }
    ?>