我想创建一个应用程序网址“ http://example.com ”。但输入网址后,它会显示“ HTTP错误403.14-禁止访问”。当我在网址的末尾(例如“ http://example.com/index.php ”)插入“ index.php”时,登录页面在浏览器中呈现,我已经更改了
$config['base_url'] = 'http://example.com';
$config['index_page'] = '';
和
$config['uri_protocol'] = 'REQUEST_URI';
在config.php文件中。然后,将.htaccess文件以及应用程序和系统文件夹放置在codeigniter根文件夹中。然后在.htaccess文件中,我已经用
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>
我只想从网址中删除“ index.php”。我正在使用IIS 8.5 Web服务器。
htaccess file
RewriteEngine on
RewriteCond $1 !^(index\.php|resources|robots\.txt)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
my site is working http://demo.crowdfundingscript.com/
config file
$config['uri_protocol'] = 'AUTO';
$config['index_page'] = '';
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句