그누보드 처음 써보는데요.. index.html에 게시판의 최근게시물을 세개정도 넣고싶은데요.
다음과 같은 오류가 떠서 진행이 안되고 있어요.
Warning: include_once(../gruboard/_common.php) [function.include-once]: failed to open stream: No such file or directory in /home/hosting_users/leeuh77/www/new/index.html on line 4
Warning: include_once() [function.include]: Failed opening '../gruboard/_common.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/hosting_users/leeuh77/www/new/index.html on line 4
Warning: include_once(G5_LIB_PATH../gnuboard/lib/latest.lib.php) [function.include-once]: failed to open stream: No such file or directory in /home/hosting_users/leeuh77/www/new/index.html on line 5
Warning: include_once() [function.include]: Failed opening 'G5_LIB_PATH../gnuboard/lib/latest.lib.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/hosting_users/leeuh77/www/new/index.html on line 5
index.html 상단에는
<?
$g5 [path]=".";
include_once('../gruboard/_common.php');
include_once(G5_LIB_PATH.'../gnuboard/lib/latest.lib.php');
?>
삽입했구요.
최신글 불러올 곳에는
<?php echo latest('basic_c', 'notice', 5, 10); ?>
했습니다.
마찬가지로
Fatal error: Call to undefined function latest() in /home/hosting_users/leeuh77/www/new/index.html on line 177
라는 오류가 뜹니다.
경로가 안맞는건가요? gnuboard디렉토리안에서 작업을 해야 하는것인지요?
디렉토리는 www디렉토리안에 gnuboard디렉토리와 new디렉토리가 있으며, index.html은 new폴더 안에 있습니다.
고수님들의 조언 부탁드립니다.
답변 1개 / 댓글 2개
include_once(G5_LIB_PATH.'../gnuboard/lib/latest.lib.php');
여기 경로 수정해 보세요.
include_once(G5_LIB_PATH.'/latest.lib.php');
답변에 대한 댓글 2개
정확하게 그누보드 4, 5 어떤 걸 쓰시나요?
답변을 작성하려면 로그인이 필요합니다.
매뉴얼대로 test.php를 아래와 같이 만들어서 index.php가 있는 루트디렉토리에 넣었습니다.
<?
include_once("./_common.php");
include_once("$g4[path]/lib/latest.lib.php");
echo latest("basic", "free", 5, 70);
?>
웹에서 테스트를 해보니까 다음과 같은 오류메세지가 뜹니다.
Parse error: syntax error, unexpected ';' in /home/hosting_users/leeuh77/www/gnuboard/test.php on line 2
매뉴얼대로 했으니까 경로는 맞는것 같은데, 설치가 잘못되었을까요?