【发布时间】:2016-08-08 04:20:51
【问题描述】:
我的项目无法在线运行(cpanel) "https://www.sample.com/folder"
但我这样提供我的网址意味着工作
"https://www.sample.com/folder/index.php/controller_name"
我想要“sample.com/folder/controller_name”
如何解决这个问题。我希望我的 URL 像第一个一样
我的配置文件信息
$config['index_page'] = '';
$config['uri_protocol'] = 'REQUEST_URI';
我的Route文件是这样的,这里有什么问题吗。
$route['default_controller'] = "pages/home";
$username = '(:any)';
$route['404_override'] = '';
$route['sample/([0-9]+)'] = "sample/index/$1";
$route['pages/profile'] = "pages/profile";
$route['pages/userList'] = "pages/userList";
$route['auth/logout'] = "auth/logout";
$route['auth'] = "auth/logout";
$route['auth/login'] = "auth/login";
$route['auth/register'] = "auth/register";
$route['pages/post'] = "pages/post";
【问题讨论】:
-
这看起来不像是一个开发问题,而且您提供的信息非常少。您可能想在 serverfault.com 上提问
-
添加了关于@Quasimodo's clone 的url详细信息
标签: codeigniter url routes