简体   繁体   中英

Cannot remove index.php from url CI based site

I have Code Igniter based site and I have it on ubuntu 12.04 in /var/www/mysite folder My ubuntu serves as a server so I access my site trough other computer, but both computers are on LAN network. I use http://xxx.yyy.zzz.ttt/mysite url to access it.

The problem I have is that I cannot use url without "index.php" in it. So I have http://xxx.yyy.zzz.ttt/mysite/index.php/phpinfo To acces my controller phpinfo instead of http://xxx.yyy.zzz.ttt/mysite/phpinfo

I have cheked well that mod_revrite works well with this here And also checked that the folder, files and subfolders in mysite have all 777 file permissions.

I also added all necessary rules in .htaccess file but still no success

Any idea what is causing this.

The first thing I would do is make sure you followed all of the CI instructions .

It may be that you did not update the config file to be a blank string rather than using index.php

Do you know what was the issue.

The default file in sites-available had option

AllowOverride None for /var/wwww

I set it to All and it worked out. :)

cheers :)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM