Welcome Guest, Not a member yet? Register   Sign In
problem with removing index.php
#11

[eluser]Skuja[/eluser]
the same as described in first post:
http://localhost/test/test_controller/test
#12

[eluser]ekeretex[/eluser]
The url you want to get is http://localhost/test_controller/test (the test_controller class and the test method).

With mod_rewrite enabled, both http://localhost/test_controller/test and http://localhost/index.php/test_controller/test should work.
#13

[eluser]Skuja[/eluser]
maybe theres something wrong in .htaccess file ?
Code:
<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>

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

[eluser]ekeretex[/eluser]
Does the url work with the index.php in it?
Remove the if condition and see if that works. It think the loaded module for my setup is mod_rewrite.so. Not sure if that's the same but I don't use the conditional with mine.
Code:
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
If that doesn't work comment out the RewriteBase line and try again.
#15

[eluser]Skuja[/eluser]
Thank you ekeretex for spending your time to help me, it wroks now when i removed conditional statement and rewritebase!
#16

[eluser]ekeretex[/eluser]
No problem at all. Glad I could help
#17

[eluser]chamu_cfi[/eluser]
Thanks it worked for me!!!
#18

[eluser]citm[/eluser]
I am new in code igniter and I have the same problem:

I've created .htaccess file and I've put it in the same root that index.php:

<code>

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

</code>

The result is 500 inernal server error

I want this structure:

http://www.mydomain.com/myclass/

and not

http://www.mydomain.com/index.php/myclass/

Thanks in advance!!!
#19

[eluser]chamu_cfi[/eluser]
This is my .htaccess file content:

Code:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]

try also setting this in your config/config.php file..

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

PD: I'm running xampp on Windows XP
#20

[eluser]Skuja[/eluser]
Did you guys checked that everything is set as described in this tutorial: http://codeigniter.com/wiki/mod_rewrite/ ?
and as I said, it worked for me, when I removed following line from .htaccess file

Code:
RewriteBase /




Theme © iAndrew 2016 - Forum software by © MyBB