• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
get rid of index.php

Ok this is sound like a simple as it documents in CI.  I tested run on a project that is migrated to
Ubuntu 16.04.02 and the ci is under directory like var/www/myproject

I made all changes as neccessary per document to .htaccess and it drives me nut as I still cant
get rid of index.php within url such as http://myproject.com/showsomething
instead it requires http://myproject.com/index.php/showsomething!

I am not sure if the Ubuntu 16.04.02 is varied with the config somewhere.  I scratched my head
do almost all as I can try.

All other projects running on Ubuntu 14.04 are fine with htaccess I set up which is same as per doc suggestion

Anyone has any ideas?


Here is my sample .htaccess file

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /openspire/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /openspire/index.php [L]

Also make sure that your mod_rewrite is also enabled
There are those who tell lies with meaning behind them and those meaning less lies!

Unfortunately it is still not working, here is my current .htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]

And runs apache2 -v showing Server version: Apache/2.4.18 (Ubuntu)

My app is at var/www/myapp

And the config.php has been set up to show no index.php such as
$config['index_page'] = '';

Also mod rewrite has been enabled

Any help is greatly appreciated


PS: I have no issues at all under Ubuntu 14.04

OK at last, I found the config issue at apache2.conf. Solved

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

Users browsing this thread:
1 Guest(s)

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2018 MyBB Group.