Welcome Guest, Not a member yet? Register   Sign In
Mod rewrite missing in 2.1.2?
#1

[eluser]AlanW[/eluser]
I was reading some instructions on how to get rid of the index.php and they said to find the mod rewrite on the wiki at https://github.com/EllisLab/CodeIgniter/wiki/_pages

The page seems to be missing? Has 2.1.2 changed this functionality? Where are the latest instructions to getting rid of the index.php in the URL please?

Thanks in advance!
Alan
#2

[eluser]PhilTem[/eluser]
mod_rewrite is a module from your apache therefore it isn't directly related to CI. To remove index.php you need to configure the .htaccess file in your root location of your app and set

Code:
$config['index_page'] = '';

Search the forums or Google/Stackoverflow to find a proper .htaccess (as long as you got an apache2-server running)
#3

[eluser]AlanW[/eluser]
Thanks for the prompt clarification. I misunderstood from the video tutorials that it was something specific to CI.

I searched again and found this: http://ellislab.com/codeigniter/user-gui.../urls.html and it looks like this is working now:

RewriteEngine On
RewriteBase /myappdirectory/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*) index.php?/$1




Theme © iAndrew 2016 - Forum software by © MyBB