그누보드 하위디렉에서 그누보드의 헤드를 불러오고 싶습니다. 정보
그누보드 하위디렉에서 그누보드의 헤드를 불러오고 싶습니다.본문
그누보드/sub/
이런 구조에서 sub 에 있는 templet_top.php 화일에
그누보드에 있는 head_sub.php 화일을 인클루드하고 싶습니다.
sub 에 있는 templet_top.php 화일에 <? include_once "$g4[path]/head.php"; ?> 했더니
아래와 같은 에러메세지가 뜹니다.
----------------------
Warning: main(/head.php) [function.main]: failed to open stream: No such file or directory in /home/~~~~~/www/sub/templet_top.php on line 1
Warning: main() [function.include]: Failed opening '/head.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/~~~~~/www/sub/templet_top.php on line 1
-----------------------
어떻게 해야하는지 고수님들의 조언을 기다립니다.
이런 구조에서 sub 에 있는 templet_top.php 화일에
그누보드에 있는 head_sub.php 화일을 인클루드하고 싶습니다.
sub 에 있는 templet_top.php 화일에 <? include_once "$g4[path]/head.php"; ?> 했더니
아래와 같은 에러메세지가 뜹니다.
----------------------
Warning: main(/head.php) [function.main]: failed to open stream: No such file or directory in /home/~~~~~/www/sub/templet_top.php on line 1
Warning: main() [function.include]: Failed opening '/head.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/~~~~~/www/sub/templet_top.php on line 1
-----------------------
어떻게 해야하는지 고수님들의 조언을 기다립니다.
댓글 전체
$g4_path = '..';
include $g4_path.'/common.php';
include $g4['path'].'/head.sub.php';
이렇게 하시면 됩니다.
include $g4_path.'/common.php';
include $g4['path'].'/head.sub.php';
이렇게 하시면 됩니다.
$g4_path = '..';
include $g4_path.'/common.php';
include $g4['path'].'/head.sub.php';
------------------
인클루드는 됬지만
아직도 아래와 같은 문구가 뜹니다.
-----------------
Warning: main(./common.php) [function.main]: failed to open stream: No such file or directory in /home/~~~~~/www/_common.php on line 3
Warning: main() [function.include]: Failed opening './common.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/~~~~~/www/_common.php on line 3
include $g4_path.'/common.php';
include $g4['path'].'/head.sub.php';
------------------
인클루드는 됬지만
아직도 아래와 같은 문구가 뜹니다.
-----------------
Warning: main(./common.php) [function.main]: failed to open stream: No such file or directory in /home/~~~~~/www/_common.php on line 3
Warning: main() [function.include]: Failed opening './common.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/~~~~~/www/_common.php on line 3
해드의 문제였어요.
해드에서 include include_once("_common.php"); 삭제하니 됩니다.
감사드립니다.
해드에서 include include_once("_common.php"); 삭제하니 됩니다.
감사드립니다.