테스트 사이트 - 개발 중인 베타 버전입니다

최신글인데요 이미지가 한줄로만 나오네요...어케된거지요?

· 15년 전 · 1953 · 4
고수님들 부탁드립니다.
파일올립니다

<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가

$data_path = $g4[path]."/data/file/$bo_table";
$thumb_path = $data_path.'/thumb';

/* 전체 환경설정 */

$all_width = "100%"; // 테이블 폭 정의

//섬네일 사이즈
$sum_width = "260"; //가로폭
$sum_height = "170"; //세로폭

//사진 테드리 사이즈
$ph_width = $sum_width +2;
$ph_height = $sum_height +2 ;
$img_mod = "2"; //가로 이미지 수


include_once "$g4[path]/thumbEngine/dq_thumb_engine2.php";
$dqEngine['thumb_resize'] = 2;

@mkdir($thumb_path, 0707);
@chmod($thumb_path, 0707);

//코멘트와 리플글은 제외
$sql = " select * from $tmp_write_table
where wr_comment = '' and wr_reply = ''
order by wr_id DESC LIMIT 0, 1 ";
$result = sql_query($sql);
$last_con = sql_fetch_array($result);

?>


<style type="text/css">
ul, li { list-style:none; margin:0; padding:0;}
#ifocusP { width:260px; height:170px; margin:0px; border:0px }
#ifocusP_img { display:inline; position:relative; float:left; width:260px; height:170px; border:0px; overflow:hidden; }
#ifocusP_imglist { position:absolute; }
#ifocusP_imglist li { width:260px; height:170px; overflow:hidden; }
#ifocusP_imglist img { width:260px; height:170px;}
#ifocusP_ico { display:inline; float:center; width:1px;}
#ifocusP_ico li { width:10px; height:46px; cursor:pointer; opacity:0.5; -moz-opacity:0.5; filter:alpha(opacity=40); }
#ifocusP_ico img { width:260px; height:170px; }
#ifocusP_ico .current { background: url('<?=$latest_skin_path?>/image/ifocus_ico_bg.gif') no-repeat; opacity:1; -moz-opacity:1; filter:alpha(opacity=40); }
#ifocusP_subjbar { position:absolute; left:0; bottom:0; width:260px; height:46px; background:#000; opacity:0.4; -moz-opacity:0.5; filter:alpha(opacity=40); }
#ifocusP_subject { position:absolute; left:8px; bottom:5px; color:#FFFFFF;}
#ifocusP_subject .normal { display:none; }
.date {font-family:Tahoma; font-size:9px; color:#e3c191; padding-bottom:3px;}
</style>




<!---------------dq 엔진 이미지 출력-------->
<table width="100%" border="0" cellpadding=0 cellspacing="0" align="center">
<tr><td height="3"></td></tr>
<tr align="center">

<!-- 목록 -->
<? for ($i=0; $i<count($list); $i++) {
$s = $i+1;



///////////////////////////////////dq//////////////////////////////////////////
$thumb_width =$sum_width;
$thumb_height =$sum_height;

$image = urlencode($list[$i][file][0][file]); // 첫번째 파일이 이미지라면

if (preg_match("/\.(gif|jpg|png)$/i", $image))
{
//DQ엔진 인클루드 2005-03-22 석훈
//// 이 스킨에서 DQ 가 작동하기 위해서는 입력하는 이미지보다는 작게 설정해야 됨
//// $thumbimg,img src 이미지 디렉토리를 변경해야 함
$dqEngine['using_usm'] = 1;
// 1또는 0 사용, 썸네일 이미지에 언샵마스크 필터를 적용한다. (샤픈필터의 한 종류)
// GD2.0 이상, PHP 4.3.2 이외의 버전일때 기본값 1, 그외 상황에서는 기본값 0 자동선택
// 1로 지정 하더라도 GD2.0이 아니거나 PHP 4.3.2 환경이면 자동으로 0으로 재설정 된다.
$dqEngine['usm_option1'] = 60; // USM 필터의 amount(강도) 수치, 기본값 : 60
$dqEngine['usm_option2'] = 0.5; // USM 필터의 radius(반경) 수치, 기본값 : 0.5
$dqEngine['usm_option3'] = 1; // USM 필터의 threshold(제외픽셀) 수치, 기본값 : 1
// USM 필터의 세부 설정은 포토샵의 그것과 사용법이 동일합니다.
$dqEngine['thumb_resize'] = "2";
// 0, 1, 2 사용
// 0: 원본 비율 대칭 리사이즈, 1: 비율유지 안함(찌그러짐), 2: 원본비율 리사이즈 + Center Crop

$thumbsource="$g4[path]/data/file/{$bo_table}/" . $image;
$thumb_path ="$g4[path]/data/file/{$bo_table}/" . 'dq_thumb_latest_dfsssfs';

if (!is_dir($thumb_path))
{
@mkdir($thumb_path, 0707);
@chmod($thumb_path, 0707);
}

$thumbimg="$thumb_path/thumb_onlyphotosY_latest_dssffff" . $image;
make_thumb($thumb_width,$thumb_height,$thumbsource,$thumbimg);

@chmod($thumbimg, 0707);

$thumbimg2 = "<img src='{$thumbimg}' width='".$thumb_width."' height='".$thumb_height."' style='border:1 #b1b1b1 solid'>";
}
else {
$thumbimg2 = "<img src='$latest_skin_path/img/no_image.gif' width='".$thumb_width."' height='".$thumb_height."' style='border:1 #c1c1c1 solid'>";
}



///////////////////////////////////dq//////////////////////////////////////////
if($s%$cn==0 ) echo"</tr><tr><td colspan='$colspan' align=center height=0></tr><tr>";

?>
<div id="ifocusP">
<div id="ifocusP_img">
<div id="ifocusP_imglist">
<div id="ifocusP_subjbar"></div>
<div id="ifocusP_subject">
<?=$list[$i]['subject']?><br>
<span class='date'>
<?=$list[$i]['datetime']?>&nbsp;&nbsp;By.<?=$list[$i]['wr_name']?></span>
</div>
<div id="ifocusP_ico">
<a href='<?=$list[$i][href]?>'><?=$thumbimg2?></a>
</div></div></div></div>

<?
echo "</DIV>";
}

?>
<? if (count($list) == 0) { ?><tr><td colspan=4 align=center height=50><font color=#6A6A6A>게시물이 없습니다.</a></td></tr><? } ?>

</table>

댓글 작성

댓글을 작성하시려면 로그인이 필요합니다.

로그인하기

댓글 4개

15년 전
//사진 테드리 사이즈
$ph_width = $sum_width +2;
$ph_height = $sum_height +2 ;
$img_mod = "2"; //가로 이미지 수

에서

$img_mod를 $cn으로 바꿔 보세요.
15년 전
$cn으로 바꿔보앗는데도 안됩니다..어디가 잘못됫는지 모르겟네요
15년 전
///////////////////////////////////dq//////////////////////////////////////////
if($s%$cn==0 ) echo"</tr><tr><td colspan='$colspan' align=center height=0></tr><tr>";


이부분이 이상합니다
for 루푸안이라면 $s는 $i 이어야 하고 $cn은 의미가 없습니다.
미리 선언하신 $img_mod = "2"; //가로 이미지 수
즉 $img_mod 가 맞는것 같습니다.

정리하면

///////////////////////////////////dq//////////////////////////////////////////
if($i && $i%$img_mod==0 ) echo"</tr><tr><td colspan='$colspan' align=center height=0></tr><tr>";

if($i && // 이부분은 게시글이 있으면서 2줄씩 표현하라는 정확한 조건을 제시하는 겁니다.
15년 전
if($i && $i%$img_mod==0 ) echo"</tr><tr><td colspan='$colspan' align=center height=0></tr><tr>";
이렇게 해바도 계속 한줄로만 나오네요...아무리 다른걸 만져도 안되네여.
어디가 잘못됫는지 ????

게시글 목록

번호 제목
284508
284499
284492
284490
284484
284481
284478
284476
284474
284472
284470
284458
284457
284454
284453
284447
284446
284444
284441
284440