Codeigniter第一页之后的“找不到文件”

时间:2018-09-07 13:07:44

标签: php codeigniter continuous-integration

在本地主机中,我的站点正常运行,在将其发布到测试服务器中后,它无法正常工作,并显示以下内容:

enter image description here

我的登录页面运行没有问题...

enter image description here

但是,当我单击“登录”后,我收到错误消息,但是URL正确...

enter image description here

我的 config.php

$config['base_url'] = 'http://merge.***.it/merge/';
$config['index_page'] = 'index.php';

routes.php

$route['default_controller'] = 'auth/login';
$route['404_override'] = '';
$route['translate_uri_dashes'] = FALSE;

1 个答案:

答案 0 :(得分:0)

尝试一下。 在index_page中留空。

$data = [$post["weathercondition"], $post["flashintense"], $post["earthrumble"]];
$sql = "INSERT INTO `database`.`table` (`weather`, `flash`, `earth`)
        VALUES (?, ?, ?)";

$pdo->prepare($sql)->execute($data);

&在根文件夹中使用.htaccess

$config['index_page'] = '';