Welcome Guest, Not a member yet? Register   Sign In
Separating controllers so they can work on their own
#9

(04-22-2019, 10:44 PM)Wouter60 Wrote: Glad it's working now!!

To get rid of the index.php in all your URL's, just set the $config['index_page'] back to '' (empty string).
Then modify your .htaccess file in the root of your website (where index.php is located):

Code:
order allow,deny
allow from all

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

# Prevent file browsing
Options -Indexes

Actually, .htaccess will insert the index.php part if it's missing in the url, but that's just what you want for all URL's.

Now, users can access your website with URL's like:
Code:
http://culturedkink.com/register/pass

All your "anchors" and redirects will still work.

Thank you so very much Heart
Reply


Messages In This Thread
RE: Separating controllers so they can work on their own - by Mekaboo - 04-23-2019, 01:25 PM



Theme © iAndrew 2016 - Forum software by © MyBB