리스트에서 답사기 게시판 처럼 그림 다 뿌려주고, 새창 으로띄아줄라면 어떻게 하나요 ? 정보
리스트에서 답사기 게시판 처럼 그림 다 뿌려주고, 새창 으로띄아줄라면 어떻게 하나요 ?본문
리스트에서. 올린 그림다 뿌려주고..
한개한개 클릭할때 마다 새창으로 원본 크기로 열려면 어떻게 하면될까요 ?
수고하세요.. 최강그누보드..
yesmoa 님이 만든소스에 보면
<?
//--### 리스트화면에 보여줄 형태설정 ### ---//-->
$img_count = '6'; // 게시물 한건당 이미지 출력갯수
$img_width = '100'; // 이미지 개당 가로크기
$img_height = '80'; // 이미지 개당 세로크기
$Noimg = "$board_skin_path/img/no_image.gif"; // 대체 이미지
$s_content = array(); // 각 파일설명글
$img = array(); // 이미지명
for ($i=0; $i<count($list); $i++)
{
$total_img_count = $list[$i][file][count];
if ($total_img_count > $img_count) { // 지정한갯수보다 클경우 지정갯수로
$total_img_count = $img_count;
}
$title = "클릭하시면 더 많은 사진을 보실수 있습니다.";
$content = cut_str(get_text($list[$i][wr_content]), 80);
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}";
$view_href = "$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}";
if ($is_admin)
$view_href = "<a href='$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}'>";
$checkbox = "";
if ($is_checkbox)
$checkbox = "<input type=checkbox name=chk_wr_id[] value='{$list[$i][wr_id]}'>";
if ($is_admin)
$view_href = "{$g4[bbs_path]}/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}";
echo <<<HEREDOC
<tr>
<td width="" align='left' valign="top">
<table width="100%" cellpadding="2" cellspacing="0" border="0" style='border:1px solid #cccccc'>
<tr><td align='left' height='24' bgcolor='#efefef'> {$checkbox} <a class='b1' href='{$view_href}'>{$list[$i][subject]}</a></td>
</tr>
<tr>
<td>
<table width="100%" cellpadding="10" cellspacing="0" border="0" style='border:0px solid #cccccc'>
<tr>
HEREDOC;
for ($k=0; $k < $total_img_count; $k++) { // 이미지파일 갯수만큼 루트
$s_content[$k] = cut_str(get_text($list[$i][file][$k][content]), 12, '...'); //-- 각각의 사진설명글 줄이기
$img[$k] = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][$k][file]); // 각각의 이미지 저장
if (!file_exists($img[$k]) || !$list[$i][file][$k][file]) { // 이미지가 없다면 대체이미지로 출력
$img[$k] = "$board_skin_path/img/no_image.gif";
}
echo <<<HEREDOC
<td align='center' valign='top'><a class='b1' href='{$view_href}'><img src="{$img[$k]}" width="{$img_width}" height="{$img_height}" style="border:2px solid #666666">
<br>{$s_content[$k]}</a>
</td>
HEREDOC;
}
if ($total_img_count < $img_count) { // 지정된 갯수보다 적으면 나머지를 대체이미지로 출력
for ($k=$total_img_count; $k< $img_count ; $k++) {
echo <<<HEREDOC
<td align='center'>
<img src="{$Noimg}" width="{$img_width}" height="{$img_height}" style="border:2px solid #666666">
<br>
</td>
HEREDOC;
}
}
echo <<<HEREDOC
</tr>
</table>
</td></tr>
</table><br>
</td>
</tr>
HEREDOC;
}
if ($i == 0) { echo "<tr><td colspan='$board[bo_gallery_cols]' height=50 align=center>게시물이 없습니다.</td></tr>"; }
?>
</form>
</table>
<!------------ 멀티 이미지 출력 끝------------------------//-->
위에처럼 있는데요. 여기서 좀수정하면 될거같기도 한데요.. 하루종일 삽질해도 안되네요..
수고하세요. 최강그누보드..
한개한개 클릭할때 마다 새창으로 원본 크기로 열려면 어떻게 하면될까요 ?
수고하세요.. 최강그누보드..
yesmoa 님이 만든소스에 보면
<?
//--### 리스트화면에 보여줄 형태설정 ### ---//-->
$img_count = '6'; // 게시물 한건당 이미지 출력갯수
$img_width = '100'; // 이미지 개당 가로크기
$img_height = '80'; // 이미지 개당 세로크기
$Noimg = "$board_skin_path/img/no_image.gif"; // 대체 이미지
$s_content = array(); // 각 파일설명글
$img = array(); // 이미지명
for ($i=0; $i<count($list); $i++)
{
$total_img_count = $list[$i][file][count];
if ($total_img_count > $img_count) { // 지정한갯수보다 클경우 지정갯수로
$total_img_count = $img_count;
}
$title = "클릭하시면 더 많은 사진을 보실수 있습니다.";
$content = cut_str(get_text($list[$i][wr_content]), 80);
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}";
$view_href = "$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}";
if ($is_admin)
$view_href = "<a href='$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}'>";
$checkbox = "";
if ($is_checkbox)
$checkbox = "<input type=checkbox name=chk_wr_id[] value='{$list[$i][wr_id]}'>";
if ($is_admin)
$view_href = "{$g4[bbs_path]}/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}";
echo <<<HEREDOC
<tr>
<td width="" align='left' valign="top">
<table width="100%" cellpadding="2" cellspacing="0" border="0" style='border:1px solid #cccccc'>
<tr><td align='left' height='24' bgcolor='#efefef'> {$checkbox} <a class='b1' href='{$view_href}'>{$list[$i][subject]}</a></td>
</tr>
<tr>
<td>
<table width="100%" cellpadding="10" cellspacing="0" border="0" style='border:0px solid #cccccc'>
<tr>
HEREDOC;
for ($k=0; $k < $total_img_count; $k++) { // 이미지파일 갯수만큼 루트
$s_content[$k] = cut_str(get_text($list[$i][file][$k][content]), 12, '...'); //-- 각각의 사진설명글 줄이기
$img[$k] = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][$k][file]); // 각각의 이미지 저장
if (!file_exists($img[$k]) || !$list[$i][file][$k][file]) { // 이미지가 없다면 대체이미지로 출력
$img[$k] = "$board_skin_path/img/no_image.gif";
}
echo <<<HEREDOC
<td align='center' valign='top'><a class='b1' href='{$view_href}'><img src="{$img[$k]}" width="{$img_width}" height="{$img_height}" style="border:2px solid #666666">
<br>{$s_content[$k]}</a>
</td>
HEREDOC;
}
if ($total_img_count < $img_count) { // 지정된 갯수보다 적으면 나머지를 대체이미지로 출력
for ($k=$total_img_count; $k< $img_count ; $k++) {
echo <<<HEREDOC
<td align='center'>
<img src="{$Noimg}" width="{$img_width}" height="{$img_height}" style="border:2px solid #666666">
<br>
</td>
HEREDOC;
}
}
echo <<<HEREDOC
</tr>
</table>
</td></tr>
</table><br>
</td>
</tr>
HEREDOC;
}
if ($i == 0) { echo "<tr><td colspan='$board[bo_gallery_cols]' height=50 align=center>게시물이 없습니다.</td></tr>"; }
?>
</form>
</table>
<!------------ 멀티 이미지 출력 끝------------------------//-->
위에처럼 있는데요. 여기서 좀수정하면 될거같기도 한데요.. 하루종일 삽질해도 안되네요..
수고하세요. 최강그누보드..
댓글 전체