Welcome Guest, Not a member yet? Register   Sign In
get rid of index.php
#1

[eluser]cerberus478[/eluser]
I'm not sure if this is the right place but I want to get rid of the index.php. I have tried various ways. I made a .htacces that has
Code:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /

RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php/$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond $1 !^(index\.php|images|robots\.txt|css)
RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>

<IfModule !mod_rewrite.c>
ErrorDocument 404 /index.php
</IfModule>

and I enabled rewrite_module

but it isn't working
#2

[eluser]cerberus478[/eluser]
I got it semi working. But when I click on a link it gives me the index.php again.

I used this .htaccess
Code:
# Customized error messages.
ErrorDocument 404 /index.php

# Set the default handler.
DirectoryIndex index.php

# Various rewrite rules.
<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)$ index.php?/$1 [L,QSA]
</IfModule>

and I put it in my root directory
#3

[eluser]du7ch[/eluser]
Did you modify the config.php file like this?

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

If index.php is still included here, links generated by site_url() will include index.php in them.
#4

[eluser]cerberus478[/eluser]
It worked thank you




Theme © iAndrew 2016 - Forum software by © MyBB