최근게시물 도움여^^;; 정보
최근게시물 도움여^^;;본문
그누보드 설치는 bbs 폴더에 했습니다.
index.htm 파일을 테스트 파일로 만들어서 작업했구요.
문제는 최근게시물을 추출하긴 했는데...
이미지도 깨지고 링크도 깨진다는 거죠.
이미지 속성을 보면 절대주소와 상대주소가 겹친듯 한데...
아마도 그누보드의 위치 문제이거나
외부 노출 php 부분을 수정해야 하지 않을까 고민하고 있습니다.
고수분들의 조언 부탁드립니다.
http://geo365.co.kr/index.htm
index.htm 파일을 테스트 파일로 만들어서 작업했구요.
문제는 최근게시물을 추출하긴 했는데...
이미지도 깨지고 링크도 깨진다는 거죠.
이미지 속성을 보면 절대주소와 상대주소가 겹친듯 한데...
아마도 그누보드의 위치 문제이거나
외부 노출 php 부분을 수정해야 하지 않을까 고민하고 있습니다.
고수분들의 조언 부탁드립니다.
http://geo365.co.kr/index.htm
댓글 전체
최근 게시물에 링크 앞쪽 화살표 이미지는 강제로 주소 잡아서 나오는데...
뒤쪽 이미지는 랜덤이기도 하거니와 php 함수를 건드려야 하는 관계로... ㄷㄷㄷ
뒤쪽 이미지는 랜덤이기도 하거니와 php 함수를 건드려야 하는 관계로... ㄷㄷㄷ
<img src="<?=$g4[path]?>/img/icon_new.gif">
아 랜덤이미지로 나오게 해야하나요?
http://geo365.co.kr/bbs/skin/latest/basic/img/icon_new.gif
지금 이거 위에 주소있는 아이콘 말씀하시는거죠?
지금 이거 위에 주소있는 아이콘 말씀하시는거죠?
http://geo365.co.kr/home/geo365/public_html/bbs/skin/latest/basic/img/icon_new.gif
지금 이렇게 되어있으신대요...
<img src="<?=$g4[path]?>/img/icon_new.gif"> 이렇게 하시면
http://geo365.co.kr/bbs/skin/latest/basic/img/icon_new.gif 이렇게 됩니다.
지금 이렇게 되어있으신대요...
<img src="<?=$g4[path]?>/img/icon_new.gif"> 이렇게 하시면
http://geo365.co.kr/bbs/skin/latest/basic/img/icon_new.gif 이렇게 됩니다.
latest.skin.php 파일을 수정해야 할듯 한데요.
아래 내용입니다. 말씀하신 부분이 어딜 수정해야 하는지...ㄷㄷㄷ
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<table width=100% cellpadding=0 cellspacing=0>
<? for ($i=0; $i<count($list); $i++) { ?>
<tr>
<td align=center>
<table width=95%>
<tr>
<td height=25><img src='bbs/skin/latest/basic/img/latest_icon.gif' align=absmiddle>
<a href="cust-01.htm" target="self"><?
echo $list[$i]['icon_reply'] . " ";
echo "<a href='{$list[$i]['href']}'>";
if ($list[$i]['is_notice'])
echo "<font style='font-family:돋움; font-size:9pt; color:#2C88B9;'><strong>{$list[$i]['subject']}</strong></font>";
else
echo "<font style='font-family:돋움; font-size:9pt; color:#6A6A6A;'>{$list[$i]['subject']}</font>";
echo "</a>";
if ($list[$i]['comment_cnt'])
echo " <a href=\"{$list[$i]['comment_href']}\"><span style='font-family:돋움; font-size:8pt; color:#9A9A9A;'>{$list[$i]['comment_cnt']}</span></a>";
// if ($list[$i]['link']['count']) { echo "[{$list[$i]['link']['count']}]"; }
// if ($list[$i]['file']['count']) { echo "<{$list[$i]['file']['count']}>"; }
echo " " . $list[$i]['icon_new'];
echo " " . $list[$i]['icon_file'];
echo " " . $list[$i]['icon_link'];
echo " " . $list[$i]['icon_hot'];
echo " " . $list[$i]['icon_secret'];
?></a></td></tr>
<tr><td bgcolor=#EBEBEB height=1></td></tr>
</table></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><tr><td align=center height=50><font color=#6A6A6A>게시물이 없습니다.</font></td></tr><? } ?>
</table>
아래 내용입니다. 말씀하신 부분이 어딜 수정해야 하는지...ㄷㄷㄷ
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<table width=100% cellpadding=0 cellspacing=0>
<? for ($i=0; $i<count($list); $i++) { ?>
<tr>
<td align=center>
<table width=95%>
<tr>
<td height=25><img src='bbs/skin/latest/basic/img/latest_icon.gif' align=absmiddle>
<a href="cust-01.htm" target="self"><?
echo $list[$i]['icon_reply'] . " ";
echo "<a href='{$list[$i]['href']}'>";
if ($list[$i]['is_notice'])
echo "<font style='font-family:돋움; font-size:9pt; color:#2C88B9;'><strong>{$list[$i]['subject']}</strong></font>";
else
echo "<font style='font-family:돋움; font-size:9pt; color:#6A6A6A;'>{$list[$i]['subject']}</font>";
echo "</a>";
if ($list[$i]['comment_cnt'])
echo " <a href=\"{$list[$i]['comment_href']}\"><span style='font-family:돋움; font-size:8pt; color:#9A9A9A;'>{$list[$i]['comment_cnt']}</span></a>";
// if ($list[$i]['link']['count']) { echo "[{$list[$i]['link']['count']}]"; }
// if ($list[$i]['file']['count']) { echo "<{$list[$i]['file']['count']}>"; }
echo " " . $list[$i]['icon_new'];
echo " " . $list[$i]['icon_file'];
echo " " . $list[$i]['icon_link'];
echo " " . $list[$i]['icon_hot'];
echo " " . $list[$i]['icon_secret'];
?></a></td></tr>
<tr><td bgcolor=#EBEBEB height=1></td></tr>
</table></td>
</tr>
<? } ?>
<? if (count($list) == 0) { ?><tr><td align=center height=50><font color=#6A6A6A>게시물이 없습니다.</font></td></tr><? } ?>
</table>
그리고 지금 보시면 게시물로 올라와 있는 하이퍼링크도 깨져 있습니다. 이부분도 이미지와 비슷하게 중복된 주소가 문제인거 같은데 어느 php를 수정 해줘야 하는지 조언 부탁드립니다...
latest.lib.php
이게 링크 쪽인거 같은데... 이부분도 수정을...^^;;
<?
if (!defined('_GNUBOARD_')) exit;
// 최신글 추출
function latest($skin_dir="", $bo_table, $rows=10, $subject_len=40, $options="")
{
global $g4;
if ($skin_dir)
$latest_skin_path = "$g4[path]/skin/latest/$skin_dir";
else
$latest_skin_path = "$g4[path]/skin/latest/basic/img";
$list = array();
$sql = " select * from $g4[board_table] where bo_table = '$bo_table'";
$board = sql_fetch($sql);
$tmp_write_table = $g4['write_prefix'] . $bo_table; // 게시판 테이블 전체이름
//$sql = " select * from $tmp_write_table where wr_is_comment = 0 order by wr_id desc limit 0, $rows ";
// 위의 코드 보다 속도가 빠름
$sql = " select * from $tmp_write_table where wr_is_comment = 0 order by wr_num limit 0, $rows ";
//explain($sql);
$result = sql_query($sql);
for ($i=0; $row = sql_fetch_array($result); $i++)
$list[$i] = get_list($row, $board, $latest_skin_path, $subject_len);
ob_start();
include "$latest_skin_path/latest.skin.php";
$content = ob_get_contents();
ob_end_clean();
return $content;
}
?>
이게 링크 쪽인거 같은데... 이부분도 수정을...^^;;
<?
if (!defined('_GNUBOARD_')) exit;
// 최신글 추출
function latest($skin_dir="", $bo_table, $rows=10, $subject_len=40, $options="")
{
global $g4;
if ($skin_dir)
$latest_skin_path = "$g4[path]/skin/latest/$skin_dir";
else
$latest_skin_path = "$g4[path]/skin/latest/basic/img";
$list = array();
$sql = " select * from $g4[board_table] where bo_table = '$bo_table'";
$board = sql_fetch($sql);
$tmp_write_table = $g4['write_prefix'] . $bo_table; // 게시판 테이블 전체이름
//$sql = " select * from $tmp_write_table where wr_is_comment = 0 order by wr_id desc limit 0, $rows ";
// 위의 코드 보다 속도가 빠름
$sql = " select * from $tmp_write_table where wr_is_comment = 0 order by wr_num limit 0, $rows ";
//explain($sql);
$result = sql_query($sql);
for ($i=0; $row = sql_fetch_array($result); $i++)
$list[$i] = get_list($row, $board, $latest_skin_path, $subject_len);
ob_start();
include "$latest_skin_path/latest.skin.php";
$content = ob_get_contents();
ob_end_clean();
return $content;
}
?>
이상은 읎어보이는대요.
home/geo365/public_html/bbs 이렇게 보이는데... 주소는 -_-ㅋ
home/geo365/public_html/bbs 이렇게 보이는데... 주소는 -_-ㅋ
내공 높으신분 기다려보세요...