cheditor 사용중인데.,,..이미지첨부시 최신갤러리 노출방법좀 알려주세요! 정보
cheditor 사용중인데.,,..이미지첨부시 최신갤러리 노출방법좀 알려주세요!본문
사진에서 보이는건 최신이미지로 빼온것입니다.
근데 사진첨부하면 이미지가 안보여지고 파일첨부하면 이미지가 보여지네요~
다른거 적용해도 다 그렇고요!
ㅠㅠ죄송한데 방법좀 부탁드립니다.
하루종일 고생중!ㅠㅠ
----------갤러리 최신 소스입니다.------------------------------
<?
if (!defined("_GNUBOARD_")) exit; //
?><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table1">
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td>
</td>
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
</table>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table6">
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<? for ($i=0; $i<count($list); $i++) {?>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td width="5"></td>
<td height="21">
<table width=100% cellpadding=0 cellspacing=0 style="border-collapse:collapse;" style="border-top-width:0; border-right-width:0; border-bottom-width:0; border-left-width:0; border-top-color:rgb(181,181,181); border-right-colorrgb(181,181,181); border-bottom-color:rgb(181,181,181); border-left-color:rgb(181,181,181); border-style:solid;" id="table7">
<colgroup width=14>
<colgroup>
<colgroup width=37>
<colgroup width=14>
<tr>
<td width="100%" style="border-width:0; border-color:black; border-style:solid;">
<table width=0 border=0 id="table8">
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
if ($i > 0)
echo '';
$title = get_text($list[$i][wr_subject]);
$content = cut_str(get_text($list[$i][wr_content]), 80);
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
if (!file_exists($img) || !$list[$i][file][0][file])
$img = "$latest_skin_path/img/no_image.gif";
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table";
echo <<<HEREDOC
<td width='0' valign='top' align=''>
<table border="0" id="table2" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" id="table3" cellspacing="1" bgcolor="#DFDAC8">
<tr>
<td bgcolor="#FFFFFF">
<a href="{$list[$i][href]}">
<img style="FILTER: alpha(opacity=100)" onmouseover="this.style.filter = 'alpha(opacity=50)';" onmouseout="this.style.filter='none';" border="0" src="{$img}" width="93" height="80"></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
HEREDOC;
}
?>
</tr>
</table>
<? if (count($list) == 0) { ?>아직없음.<? } ?></tr></table>
</td>
<!--게시물 추출 글자 설정 끝-->
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><? } ?>
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="4"></td>
</tr>
</table>
부탁합니다!
근데 사진첨부하면 이미지가 안보여지고 파일첨부하면 이미지가 보여지네요~
다른거 적용해도 다 그렇고요!
ㅠㅠ죄송한데 방법좀 부탁드립니다.
하루종일 고생중!ㅠㅠ
----------갤러리 최신 소스입니다.------------------------------
<?
if (!defined("_GNUBOARD_")) exit; //
?><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table1">
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td>
</td>
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
</table>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table6">
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<? for ($i=0; $i<count($list); $i++) {?>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td width="5"></td>
<td height="21">
<table width=100% cellpadding=0 cellspacing=0 style="border-collapse:collapse;" style="border-top-width:0; border-right-width:0; border-bottom-width:0; border-left-width:0; border-top-color:rgb(181,181,181); border-right-colorrgb(181,181,181); border-bottom-color:rgb(181,181,181); border-left-color:rgb(181,181,181); border-style:solid;" id="table7">
<colgroup width=14>
<colgroup>
<colgroup width=37>
<colgroup width=14>
<tr>
<td width="100%" style="border-width:0; border-color:black; border-style:solid;">
<table width=0 border=0 id="table8">
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
if ($i > 0)
echo '';
$title = get_text($list[$i][wr_subject]);
$content = cut_str(get_text($list[$i][wr_content]), 80);
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
if (!file_exists($img) || !$list[$i][file][0][file])
$img = "$latest_skin_path/img/no_image.gif";
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table";
echo <<<HEREDOC
<td width='0' valign='top' align=''>
<table border="0" id="table2" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" id="table3" cellspacing="1" bgcolor="#DFDAC8">
<tr>
<td bgcolor="#FFFFFF">
<a href="{$list[$i][href]}">
<img style="FILTER: alpha(opacity=100)" onmouseover="this.style.filter = 'alpha(opacity=50)';" onmouseout="this.style.filter='none';" border="0" src="{$img}" width="93" height="80"></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
HEREDOC;
}
?>
</tr>
</table>
<? if (count($list) == 0) { ?>아직없음.<? } ?></tr></table>
</td>
<!--게시물 추출 글자 설정 끝-->
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><? } ?>
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="4"></td>
</tr>
</table>
부탁합니다!
댓글 전체

소스중
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
if (!file_exists($img) || !$list[$i][file][0][file])
$img = "$latest_skin_path/img/no_image.gif";
이 소스가 있는데 이 소스는 첫번째 파일첨부가 있을경우 이미지를 보여주고 없을때는 노이미지를 뿌려준다는 소스입니다.
에디터에서 사진첨부하는것은 따로 관련소스를 넣으셔야 합니다.
해당게시물의 본문내용중에서 img 를 찾아내고 그 사진을 썸네일로 만들어서 놓는 구조입니다.
http://www.sir.co.kr/bbs/board.php?bo_table=g4_tiptech&wr_id=3643&sca=&sfl=wr_subject&stx=%C3%B7%BA%CE&sop=and&page=2
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
if (!file_exists($img) || !$list[$i][file][0][file])
$img = "$latest_skin_path/img/no_image.gif";
이 소스가 있는데 이 소스는 첫번째 파일첨부가 있을경우 이미지를 보여주고 없을때는 노이미지를 뿌려준다는 소스입니다.
에디터에서 사진첨부하는것은 따로 관련소스를 넣으셔야 합니다.
해당게시물의 본문내용중에서 img 를 찾아내고 그 사진을 썸네일로 만들어서 놓는 구조입니다.
http://www.sir.co.kr/bbs/board.php?bo_table=g4_tiptech&wr_id=3643&sca=&sfl=wr_subject&stx=%C3%B7%BA%CE&sop=and&page=2

1. 아래의 링크에서 thumb.lib.php 파일을 받아 그누보드의 lib 폴더에 업로드 하세요.
http://sir.co.kr/bbs/board.php?bo_table=g4_pi_thumb&wr_id=778
(불당썸을 설치 하는 것입니다. thumb.lib.php만 받아서 업로드 하면 됩니다.)
2. 최신글 소스를 아래 소스로 전체 바꿔주세요.
<?
if (!defined("_GNUBOARD_")) exit; //
include_once("$g4[path]/lib/thumb.lib.php");
$thumb_width = "93"; //썸네일 가로길이
$thumb_height = "80"; //썸네일 세로길이
$filter[type] = 99;
$filter[arg1] = 100;
$filter[arg2] = 1;
$filter[arg3] = 2;
?>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table1">
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td>
</td>
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
</table>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table6">
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<? for ($i=0; $i<count($list); $i++) {?>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td width="5"></td>
<td height="21">
<table width=100% cellpadding=0 cellspacing=0 style="border-collapse:collapse;" style="border-top-width:0; border-right-width:0; border-bottom-width:0; border-left-width:0; border-top-color:rgb(181,181,181); border-right-colorrgb(181,181,181); border-bottom-color:rgb(181,181,181); border-left-color:rgb(181,181,181); border-style:solid;" id="table7">
<colgroup width=14>
<colgroup>
<colgroup width=37>
<colgroup width=14>
<tr>
<td width="100%" style="border-width:0; border-color:black; border-style:solid;">
<table width=0 border=0 id="table8">
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
if ($i > 0)
echo '';
$title = get_text($list[$i][wr_subject]);
$content = cut_str(get_text($list[$i][wr_content]), 80);
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
$file = $list[$i][file][0][path] .'/'. $list[$i][file][0][file];
$noimg = "$latest_skin_path/img/no_image.gif";
// 업로드된 파일이 이미지라면
if (preg_match("/\.(jpg|gif|png)$/i", $file) && file_exists($file)) {
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); //첨부 이미지 썸네일 만듬
} else { // 치에디터 이미지 추출
$edit_img = $list[$i]['wr_content'];
if (eregi("data/cheditor4[^<>]*\.(gif|jp[e]?g|png|bmp)", $edit_img, $tmp)) { // data/cheditor------
$file = '../' . $tmp[0]; // 파일명
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); // 에디터 이미지 썸네일 만듬
}
}
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table";
echo <<<HEREDOC
<td width='0' valign='top' align=''>
<table border="0" id="table2" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" id="table3" cellspacing="1" bgcolor="#DFDAC8">
<tr>
<td bgcolor="#FFFFFF">
<a href="{$list[$i][href]}">
<img style="FILTER: alpha(opacity=100)" onmouseover="this.style.filter = 'alpha(opacity=50)';" onmouseout="this.style.filter='none';" border="0" src="{$thumfile}" width="93" height="80"></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
HEREDOC;
}
?>
</tr>
</table>
<? if (count($list) == 0) { ?>아직없음.<? } ?></tr></table>
</td>
<!--게시물 추출 글자 설정 끝-->
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><? } ?>
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="4"></td>
</tr>
</table>
http://sir.co.kr/bbs/board.php?bo_table=g4_pi_thumb&wr_id=778
(불당썸을 설치 하는 것입니다. thumb.lib.php만 받아서 업로드 하면 됩니다.)
2. 최신글 소스를 아래 소스로 전체 바꿔주세요.
<?
if (!defined("_GNUBOARD_")) exit; //
include_once("$g4[path]/lib/thumb.lib.php");
$thumb_width = "93"; //썸네일 가로길이
$thumb_height = "80"; //썸네일 세로길이
$filter[type] = 99;
$filter[arg1] = 100;
$filter[arg2] = 1;
$filter[arg3] = 2;
?>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table1">
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td>
</td>
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="3"></td>
</tr>
</table>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table6">
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<? for ($i=0; $i<count($list); $i++) {?>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td width="5"></td>
<td height="21">
<table width=100% cellpadding=0 cellspacing=0 style="border-collapse:collapse;" style="border-top-width:0; border-right-width:0; border-bottom-width:0; border-left-width:0; border-top-color:rgb(181,181,181); border-right-colorrgb(181,181,181); border-bottom-color:rgb(181,181,181); border-left-color:rgb(181,181,181); border-style:solid;" id="table7">
<colgroup width=14>
<colgroup>
<colgroup width=37>
<colgroup width=14>
<tr>
<td width="100%" style="border-width:0; border-color:black; border-style:solid;">
<table width=0 border=0 id="table8">
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
if ($i > 0)
echo '';
$title = get_text($list[$i][wr_subject]);
$content = cut_str(get_text($list[$i][wr_content]), 80);
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
$file = $list[$i][file][0][path] .'/'. $list[$i][file][0][file];
$noimg = "$latest_skin_path/img/no_image.gif";
// 업로드된 파일이 이미지라면
if (preg_match("/\.(jpg|gif|png)$/i", $file) && file_exists($file)) {
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); //첨부 이미지 썸네일 만듬
} else { // 치에디터 이미지 추출
$edit_img = $list[$i]['wr_content'];
if (eregi("data/cheditor4[^<>]*\.(gif|jp[e]?g|png|bmp)", $edit_img, $tmp)) { // data/cheditor------
$file = '../' . $tmp[0]; // 파일명
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); // 에디터 이미지 썸네일 만듬
}
}
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table";
echo <<<HEREDOC
<td width='0' valign='top' align=''>
<table border="0" id="table2" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" id="table3" cellspacing="1" bgcolor="#DFDAC8">
<tr>
<td bgcolor="#FFFFFF">
<a href="{$list[$i][href]}">
<img style="FILTER: alpha(opacity=100)" onmouseover="this.style.filter = 'alpha(opacity=50)';" onmouseout="this.style.filter='none';" border="0" src="{$thumfile}" width="93" height="80"></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
HEREDOC;
}
?>
</tr>
</table>
<? if (count($list) == 0) { ?>아직없음.<? } ?></tr></table>
</td>
<!--게시물 추출 글자 설정 끝-->
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><? } ?>
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
<tr height="1">
<td bgcolor="#d9d9d9" colspan="4"></td>
</tr>
</table>
님아! 이해가 안되요.ㅠㅠㅠ

해보실 의지가 전혀 없는 분 같군요. -_-
아닌데...계속 해보고 있은데 계속 엑박뜨는데요.ㅠㅠ

제가 글 작성한지 1분만에 이해가 안간다고 하셔서 한말입니다..;;
else { // 치에디터 이미지 추출
$edit_img = $list[$i]['wr_content'];
if (eregi("data/cheditor4[^<>]*\.(gif|jp[e]?g|png|bmp)", $edit_img, $tmp)) { // data/cheditor------
$file = '../' . $tmp[0]; // 파일명
이 부분의 맨 끝에
$file = '../' . $tmp[0]; // 파일명 <-- 이 부분을
$file = $g4[path].'/' . $tmp[0]; // 파일명 <-- 이렇게 바꿔보세요.
else { // 치에디터 이미지 추출
$edit_img = $list[$i]['wr_content'];
if (eregi("data/cheditor4[^<>]*\.(gif|jp[e]?g|png|bmp)", $edit_img, $tmp)) { // data/cheditor------
$file = '../' . $tmp[0]; // 파일명
이 부분의 맨 끝에
$file = '../' . $tmp[0]; // 파일명 <-- 이 부분을
$file = $g4[path].'/' . $tmp[0]; // 파일명 <-- 이렇게 바꿔보세요.
하라는내로 꼼꼼히 따져가며 수정했는데...
여전히 사진첨부하면 이미지 깨지고
파일첨부해야 최신 갤러리로 이미지가 보여지네요..ㅠㅠㅠ
<?
if (!defined("_GNUBOARD_")) exit; //
?><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table6">
<? for ($i=0; $i<count($list); $i++) {?>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td width="5"></td>
<td height="21">
<table width=100% cellpadding=0 cellspacing=0 style="border-collapse:collapse;" style="border-top-width:0; border-right-width:0; border-bottom-width:0; border-left-width:0; border-top-color:rgb(181,181,181); border-right-colorrgb(181,181,181); border-bottom-color:rgb(181,181,181); border-left-color:rgb(181,181,181); border-style:solid;" id="table7">
<colgroup width=14>
<colgroup>
<colgroup width=37>
<colgroup width=14>
<tr>
<td width="100%" style="border-width:0; border-color:black; border-style:solid;">
<table width=0 border=0 id="table8">
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
if ($i > 0)
echo '';
$title = get_text($list[$i][wr_subject]);
$content = cut_str(get_text($list[$i][wr_content]), 80);
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
$file = $list[$i][file][0][path] .'/'. $list[$i][file][0][file];
$noimg = "$latest_skin_path/img/no_image.gif";
// 업로드된 파일이 이미지라면
if (preg_match("/\.(jpg|gif|png)$/i", $file) && file_exists($file)) {
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); //첨부 이미지 썸네일 만듬
} else { // 치에디터 이미지 추출
$edit_img = $list[$i]['wr_content'];
if (eregi("data/cheditor4[^<>]*\.(gif|jp[e]?g|png|bmp)", $edit_img, $tmp)) { // data/cheditor------
$file = $g4[path].'/' . $tmp[0]; // 파일명
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); // 에디터 이미지 썸네일 만듬
}
}
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table";
echo <<<HEREDOC
<td width='0' valign='top' align=''>
<table border="0" id="table2" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" id="table3" cellspacing="1" bgcolor="#DFDAC8">
<tr>
<td bgcolor="#FFFFFF">
<a href="{$list[$i][href]}">
<img style="FILTER: alpha(opacity=100)" onmouseover="this.style.filter = 'alpha(opacity=50)';" onmouseout="this.style.filter='none';" border="0" src="{$img}" width="100" height="130"></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
HEREDOC;
}
?>
</tr>
</table>
<? if (count($list) == 0) { ?>.<? } ?></tr></table>
</td>
<!--Խù -->
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><? } ?>
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
</table>
여전히 사진첨부하면 이미지 깨지고
파일첨부해야 최신 갤러리로 이미지가 보여지네요..ㅠㅠㅠ
<?
if (!defined("_GNUBOARD_")) exit; //
?><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<table align="center" cellpadding="0" cellspacing="0" width="100%" border="0" id="table6">
<? for ($i=0; $i<count($list); $i++) {?>
<tr>
<td width="1" bgcolor="#d9d9d9"></td>
<td width="5"></td>
<td height="21">
<table width=100% cellpadding=0 cellspacing=0 style="border-collapse:collapse;" style="border-top-width:0; border-right-width:0; border-bottom-width:0; border-left-width:0; border-top-color:rgb(181,181,181); border-right-colorrgb(181,181,181); border-bottom-color:rgb(181,181,181); border-left-color:rgb(181,181,181); border-style:solid;" id="table7">
<colgroup width=14>
<colgroup>
<colgroup width=37>
<colgroup width=14>
<tr>
<td width="100%" style="border-width:0; border-color:black; border-style:solid;">
<table width=0 border=0 id="table8">
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
if ($i > 0)
echo '';
$title = get_text($list[$i][wr_subject]);
$content = cut_str(get_text($list[$i][wr_content]), 80);
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
$file = $list[$i][file][0][path] .'/'. $list[$i][file][0][file];
$noimg = "$latest_skin_path/img/no_image.gif";
// 업로드된 파일이 이미지라면
if (preg_match("/\.(jpg|gif|png)$/i", $file) && file_exists($file)) {
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); //첨부 이미지 썸네일 만듬
} else { // 치에디터 이미지 추출
$edit_img = $list[$i]['wr_content'];
if (eregi("data/cheditor4[^<>]*\.(gif|jp[e]?g|png|bmp)", $edit_img, $tmp)) { // data/cheditor------
$file = $g4[path].'/' . $tmp[0]; // 파일명
$thumb = thumbnail($file, $thumb_width, $thumb_height, 0, 1, 90, 0, "", $filter, $noimg); // 에디터 이미지 썸네일 만듬
}
}
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table";
echo <<<HEREDOC
<td width='0' valign='top' align=''>
<table border="0" id="table2" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" id="table3" cellspacing="1" bgcolor="#DFDAC8">
<tr>
<td bgcolor="#FFFFFF">
<a href="{$list[$i][href]}">
<img style="FILTER: alpha(opacity=100)" onmouseover="this.style.filter = 'alpha(opacity=50)';" onmouseout="this.style.filter='none';" border="0" src="{$img}" width="100" height="130"></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
HEREDOC;
}
?>
</tr>
</table>
<? if (count($list) == 0) { ?>.<? } ?></tr></table>
</td>
<!--Խù -->
<td width="1" bgcolor="#d9d9d9"></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><? } ?>
<tr height="5"><td width="1" bgcolor="#d9d9d9" height="3"></td>
<td colspan="2" height="3"></td>
<td width="1" bgcolor="#d9d9d9" height="3"></td></tr>
</table>