Welcome Guest, Not a member yet? Register   Sign In
.htaccess (to get rid of index.php in URI) and subfolding issue (retard in the house)
#1

[eluser]Dagobert Renouf[/eluser]
Hi guys,

I'm sure you will enlight me within the few minutes with theses 2 simple issues, so let's do it :

1) I set up the .htacces file to get ird of index.php in the URI in my system/application folder, but it doesn't seem to do anything (I'm in localhost, could it be the problem ?).

Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

2) I'm creating my admin zone and the subfolding is tricking me:
- here's my tree to access the post.php controller : \system\application\controllers\admin\blog\post.php
- here's the uri I'm using : index.php/admin/blog/post/

but i have a 404 :-(.

Hope you gurus would be able to help me out.
#2

[eluser]xwero[/eluser]
1) did you remove the index.php value in the config file's index_page setting?
2) the url you should be using is site.com/admin/blog/post (remove the index.php from the url)
#3

[eluser]Dagobert Renouf[/eluser]
1) yes I did :-s
2) doesn't work either.
#4

[eluser]Dagobert Renouf[/eluser]
For the last hour I've been trying to figure this out.
I'm using WAMP server and I already made sure the url_rewritting modules and parameters were okay.

I tried using the second method of the wiki for .htaccess file
see this page but it doesn't work either.

Here's my new .htaccess file :
Code:
<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /CodeIgniter_1.6.2/
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>

<IfModule !mod_rewrite.c>
    # If we don't have mod_rewrite installed, all 404's
    # can be sent to index.php, and everything works as normal.
    # Submitted by: ElliotHaughin

    ErrorDocument 404 /index.php
</IfModule>

this file is located in my ci root folder, still i have a 404 error message when trying to load /blog/ for example.
#5

[eluser]happyd119[/eluser]
I had the same problem before but it went away after I changed the RewriteBase to "/".

Hope this helps.




Theme © iAndrew 2016 - Forum software by © MyBB