开发者

Codeigniter without index.php changing in config and .htaccess not working

开发者 https://www.devze.com 2023-03-30 04:36 出处:网络
I have this issue with codeigni开发者_JAVA百科ter for my subdomain where I would like to take out index.php but is not working for some reason.

I have this issue with codeigni开发者_JAVA百科ter for my subdomain where I would like to take out index.php but is not working for some reason.

I have set .htaccess with below:

RewriteEngine on
RewriteCond $1 !^(index\.php|images|captcha|css|js|user_guide|robots\.txt)
RewriteRule ^(.*)$ index.php/$1 [L]

and also config.php index_page settings have been changed like below:

$config['index_page'] = '';

do you know why it's not working?


And this is mine

DirectoryIndex index.php
RewriteEngine on

RewriteCond $1 !^(index\.php|(.*)\.swf|forums|images|css|downloads|js|robots\.txt|favicon\.ico)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ ./index.php?$1 [L,QSA] 


This is how mine is currently setup, hope this helps.

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
0

精彩评论

暂无评论...
验证码 换一张
取 消