我是 codeigniter 的新手。我刚刚在 google 的帮助下在 CI 中创建了一个登录功能,但在这里我在登录时重定向到 URL,但它不起作用。
这是详细信息
重定向后链接是这样的 http://localhost/xpensepedia/index.php/home
这是给出 404 错误
404 Page Not Found
The page you requested was not found.
我的 Controller 是
public function index() {
$this->load->view('header');
if (($this->session->userdata('user_id') != "")) {
redirect(site_url('home'));
} else {
$this->load->view("register");
}
$this->load->view('footer');
}
最佳答案
请检查你给 home.php Controller 的类名
关于php - Codeigniter 重定向 URL 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32089716/