htaccess works on home server but not on hosting account

#11
[eluser]brianw1975[/eluser]
you need to verify with your host/system admin that mod_rewrite is being loaded by Apache, it appears that it isn't.

#12
[eluser]Ludatha[/eluser]
If it isn't enabled I would get a 500 error, but I will contact them.

#13
[eluser]Mike L[/eluser]
[quote author="Ludatha" date="1252369203"]If it isn't enabled I would get a 500 error, but I will contact them.[/quote]

Yup, you would see a 500. I'm stumped.

Try reading this wiki page you might find something.

http://codeigniter.com/wiki/mod_rewrite/

#14
[eluser]brianw1975[/eluser]
[quote author="Mike L" date="1252467044"][quote author="Ludatha" date="1252369203"]If it isn't enabled I would get a 500 error, but I will contact them.[/quote]

Yup, you would see a 500. I'm stumped.

Try reading this wiki page you might find something.

http://codeigniter.com/wiki/mod_rewrite/[/quote]

actually he wouldn't get a 500 error if the rewrite code was in <IfModule> statement, I made the suggestion because not everyone posts their entire file/code "to save space"

and: after looking at your info file again I see that you are using Apache 1.3.41 - kinda old, might need to verify that the rewrite rules/conds are formatted correctly.

from your info.php:

Quote:SERVER_SOFTWARE Apache/1.3.41 (Unix) mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.31 OpenSSL/0.9.8b PHP-CGI/0.4mm

finally: screw waiting for the host to reply, do this and see if mod_rewrite is in the output:

Code:
&lt;?php
print_r(apache_get_modules());
?&gt;

#15
[eluser]Ludatha[/eluser]
I put that in the info.php file and...
Fatal error: Call to undefined function apache_get_modules() in /home/ludatha/public_html/info.php on line 3

I really wasn't expecting that...

#16
[eluser]Daniel Moore[/eluser]
Try using the instructions at this location:
http://www.danielwmoore.com/remove_index...odeigniter

That should get you up and running.

#17
[eluser]Ludatha[/eluser]
[quote author="Daniel Moore" date="1252859152"]Try using the instructions at this location:
http://www.danielwmoore.com/remove_index...odeigniter

That should get you up and running.[/quote]

I got excited because that was allot of code Smile

But it didn't work...

There is something seriously wrong with my host...

#18
[eluser]Daniel Moore[/eluser]
If it didn't work, then you didn't try all combinations of alternative methods mentioned.

I have yet to find a host that I can't configure with some combination of the code given, as long as the host has mod_rewrite enabled.

If you would like me to get the .htaccess file working for you, I will do so for a fee. Contact me by PM and we'll make the arrangements.

#19
[eluser]Ludatha[/eluser]
[quote author="Daniel Moore" date="1252997152"]If it didn't work, then you didn't try all combinations of alternative methods mentioned.

I have yet to find a host that I can't configure with some combination of the code given, as long as the host has mod_rewrite enabled.

If you would like me to get the .htaccess file working for you, I will do so for a fee. Contact me by PM and we'll make the arrangements.[/quote]


I fixed it!!!!! I think...

Thank you very much for your time and code Smile
The problem was in my config file I needed to change $config['uri_protocol'] to "QUERY_STRING";

One slight problem, I host a website for a friend, and it doesn't work.
it is in a directory jessicademattos and the website is www.jessicademattos.com

It says 403 - Forbidden Error, how do I fix that before she finds out?


my htaccess is
Code:
allow from all
Options -Indexes
Options +FollowSymLinks
Options -MultiViews
DirectoryIndex index.php

<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteBase /
  RewriteCond %{HTTP_HOST} ^www\.ludatha\.com$ [NC]
  RewriteRule ^(.*)$ http://ludatha.com/$1 [L,R=301]
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)$ index.php?/$1 [NC,L,QSA]
</IfModule>

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

I removed the comments because otherwise I would run out of space :O

- Adam

#20
[eluser]Daniel Moore[/eluser]
You state that the problem on the friend's hosted website is a 403 error, yet the .htaccess file you show is for ludatha.com, not for jessicademattos.com. Perhaps you forgot to change the URL when copying it over to your friend's site? Fix the URL issue, though this is not your problem with the site.

You have "Options -Indexes", which means you must have a valid index file, because the site will not display a directory index. You will get a 403 error when you try to access a site that has directory index disabled (as is this) but the site does not have a valid index.

I notice if you visit "http://www.jessicademattos.com/index.php" it gives a CodeIgniter 404 file not found. That is really screwy. Make sure you actually have the files where they are supposed to go for CodeIgniter to run. Perhaps you do not have a default controller? You must have an index.php there, or else you would not get a CodeIgniter 404. Sounds like you have forgotten to assign a default controller, or have assigned an invalid default controller. Check that for your 403 problem.


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.