Problems with codeigniter on ubuntu |
[eluser]fatman[/eluser]
Hi, I've got Codeigniter on Ubuntu 10. I have an htaccess file: Code: <IfModule mod_rewrite.c> Up until now, we connected the remote server with IP and everything worked fine, now, a virtual host was defined for the server and suddenly nothing works except for the login page (index.php). I've changed $config['base_url'] in config.php but i keep getting 404. Please help
[eluser]fatman[/eluser]
Hi, Sorry for double posting but this is very urgent, if u need more data i'll be happy to give it. Please help
[eluser]InsiteFX[/eluser]
Did you set the system and application folders in the index.php file? Also check your .htaccess file. InsiteFX
[eluser]fatman[/eluser]
Thanks for replying, I did not change the location of System and Application, and like i mentioned everything worked until we defined the virtual host. My base site is sitting under a folder called 'dort', so we used to call it like this: http://<some_ip>/dort now we mapped a virtual host to dort, so we call it like: http://demo.dort.com/ What should i change in the .htaccess file? I tried removing the /dort from RewriteBase and other occurences in the file, but that didn't help. I'm a newby when it comes to Ubuntu and .htaccess, so please explain to me in laim terms if u can
[eluser]n0xie[/eluser]
Quesion 1: If you are a newbie why are you mocking about with Ubuntu? Shouldn't there be someone more qualified be doing this? Question 2: - is mod_rewrite enabled? - does the vhost work (make an index.html in your public_html/ folder and try to access it) - does your apache config allow htaccess override? - are you running FASTCGI? - did you try to remove the questionmark after index.php? - what does your apache log say? - did you try all the different uri_protocol's in your config.php?
[eluser]fatman[/eluser]
Hi, I'll try to answer all your questions: Quesion 1: If you are a newbie why are you mocking about with Ubuntu? Shouldn’t there be someone more qualified be doing this? ---> I work in a startup and we had a guy configuring Ubuntu for us and now he is gone, so i need to do my best Question 2: - is mod_rewrite enabled? - yes - does the vhost work (make an index.html in your public_html/ folder and try to access it) - I am able to access login page (index.php). - does your apache config allow htaccess override? - yes - are you running FASTCGI? - sorry but i don't know - did you try to remove the questionmark after index.php? - no, will try - what does your apache log say? - where can i find it? - did you try all the different uri_protocol’s in your config.php? - no, will try Thanks.
[eluser]n0xie[/eluser]
[quote author="fatman" date="1298408827"] - what does your apache log say? - where can i find it? [/quote] Most likely: Code: /var/log/apache2/other_vhosts_access.log
[eluser]a_bains[/eluser]
Let me see if i can offer some help.. You didn't mention to us whether you are accessing the URLs with index.php or without. But this seemed to help me get it working without the index.php in the URLs. I am running CodeIgniter on Ubuntu 10 as well. Go into your Apache virtual host file and change the "AllowOverride" from none to FileInfo. Then restart Apache and give CodeIgniter a try. Your apache virtual host config should look something like below: Code: <Directory /> And my .htaccess file looks like this (its custom): Code: RewriteEngine on
[eluser]Toppy[/eluser]
[quote author="fatman" date="1298342953"]Hi, I've got Codeigniter on Ubuntu 10. I have an htaccess file: Code: <IfModule mod_rewrite.c> Up until now, we connected the remote server with IP and everything worked fine, now, a virtual host was defined for the server and suddenly nothing works except for the login page (index.php). I've changed $config['base_url'] in config.php but i keep getting 404. Please help [/quote] You mentioned that before the change you were accessing via: http://<some_ip>/dort and now mapped a virtual host to the dort directory (so dort is now the host root directory). If that's the case you should start by editing your .htaccess and remove the /dort part from the rewrite rules. See what that does. |
Welcome Guest, Not a member yet? Register Sign In |