Welcome Guest, Not a member yet? Register   Sign In
URL now requires index.php after I moved my application to a public hosting ( works fine in my localhost)
#1

[eluser]Oussama M Billah[/eluser]
Hello,

In my localhost, everything works fine and I dont need to include index.php in my urls. But after I moved my application to the hosting service ( hosting with eatj), I have to put the index.php back in the url or I get a 404 not found error.

I know in my local host I m enabling mod_rewrite. but i dont know how to check in the public server (I cant access the apache configuration)
Here is my .httaccess file:

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

in my config.php file:

I tried all the different options for URI_protocol. I have PATH_INFO in my localhost.

Any idea what can be wrong?

Thanks
#2

[eluser]Dam1an[/eluser]
create a fil with phpinfo() in it, and go to that page
Look for mod_rewrite in the Loaded Modules section
#3

[eluser]Oussama M Billah[/eluser]
Thanks for your replay,

I did not find any section called loaded modules. However, there is additional modules which is empty.

does that mean that mod_rewrite is not enabled. if not, how can I enable it without having access to httpd.conf file??

thanks
#4

[eluser]Oussama M Billah[/eluser]
I followed this article that let you check if mod_rewrite is enabled or not.
http://www.wallpaperama.com/disp-post19.html

and based on the article, I have mod_rewrite enabled. so I guess mod_rewrite is not the problem.

Also, The 404 error that I get is the browser default 404 error page, Not the custom CI 404 page.

I hope this will help.

Thanks in advance
#5

[eluser]Oussama M Billah[/eluser]
I tried to put random characters in the .htaccess and no error is produced. so I guess the .htaccess is not used. How can I change the apache configuration without having access to the hosting apache configuration file?

Thanks




Theme © iAndrew 2016 - Forum software by © MyBB