CI 묻고 답하기

제목 ci4 사용중인데 자꾸 index.php에서 paths.php를 열수없다고 나오네요
카테고리 CI 4 관련
글쓴이 Luten 작성시각 2021/01/08 11:33:04
댓글 : 5 추천 : 0 스크랩 : 0 조회수 : 8630   RSS

Warning: require(/host/home3/newhost/html/../app/Config/Paths.php): failed to open stream: No such file or directory in /host/home3/newhost/html/index.php on line 32

Warning: require(/host/home3/newhost/html/../app/Config/Paths.php): failed to open stream: No such file or directory in /host/home3/newhost/html/index.php on line 32

Fatal error: require(): Failed opening required '/host/home3/newhost/html/../app/Config/Paths.php' (include_path='.:/usr/share/pear:/usr/share/php') in /host/home3/newhost/html/index.php on line 32

접속하면 index.php에서 열수없다고 나오면서 제대로 실행이 되지가 않네요.

 

<?php

$minPHPVersion = '7.2';

if (phpversion() < $minPHPVersion)

{

die("Your PHP version must be {$minPHPVersion} or higher to run CodeIgniter. Current version: " . phpversion());

}

unset($minPHPVersion);

define('FCPATH', __DIR__ . DIRECTORY_SEPARATOR);

$pathsPath = realpath(FCPATH . '/host/home3/newhost/html/app/Config/Paths.php') ?: FCPATH . '/host/home3/newhost/html/app/Config/Paths.php';

chdir(__DIR__);

require $pathsPath;(오류뜨는 문구)

$paths = new Config\Paths();

$app = require rtrim($paths->systemDirectory, '/ ') . '/bootstrap.php';

 

$app->run();

 

index.php의 전문입니다.

어떻게 해결해야하나요?

 다음글 do_upload 멀티업로드 업로드 권한문제 (2)
 이전글 쿼리빌더에 대해 질문입니다. (3)

댓글

변종원(웅파) / 2021/01/08 12:15:36 / 추천 0

패스를 안맞춰주니 못찾는 겁니다.

$pathsPath = realpath(FCPATH . '../app/Config/Paths.php');

FCPATH 를 출력해보시고 위 패스를 그에 맞게 수정하세요.

 

Luten / 2021/01/08 12:25:59 / 추천 0
변종원(웅파) / 지금 써놓은 경로전에 이미 적어주신 코드를 이미 사용한적이 있는데... 똑같이 나오더라고요...
한대승(불의회상) / 2021/01/08 12:56:45 / 추천 0
$pathsPath 값을 출력해 보면 답이 나올듯
Luten / 2021/01/08 14:09:33 / 추천 0
아 경로를 다시 구체화하니 수정되었네요. 감사합니다
테러보이 / 2021/01/08 16:24:32 / 추천 0
자고로 index.php는 수정하는게....