gpt4 book ai didi

php - fatal error : Class 'AppController' not found error

转载 作者:可可西里 更新时间:2023-11-01 00:59:28 24 4
gpt4 key购买 nike

任何人都可以告诉我这个错误的来源是什么。我已经尝试了我在网上找到的所有解决方案,但都无济于事。我刚刚安装了一个 cakePHP 框架,但在 index.cpt 页面上出现了这个错误...

错误: fatal error :在第 2 行的 [mypath] 中找不到类“AppController”

<?php
class HomeController extends AppController {
function index() {
//nothing's here
}
}
?>

上面是我的代码...homeController.php 和 appController.php 在同一个文件夹里

最佳答案

经过多次搜索,这解决了我的问题

<?php
namespace App\Controller;
use App\Controller\AppController;
class HomeController extends AppController{
public function index(){

}
}

关于php - fatal error : Class 'AppController' not found error,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31598206/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com