I'm working with a codeigniter project and I am able to use codeigniter out of the box when I install it on a digital ocean ubuntu droplet. However, when I load this project I want to use, if index.php is not in the url, the project breaks and I see a 404 error: The requested URL was not found on this server.
There is a login page at domain.com/index.php/login Even when I login, it gets redirected to domain.com/dashboard without the index.php
This is my .htaccess:
RewriteEngine on
RewriteCond $1 !^(index.php|resources|robots.txt)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L,QSA]
This is my config.php:
$config['index_page'] = '';
$config['base_url'] = 'http://my_really_cool_domain.com';
Oddly enough, if I add /index.php/ to the base_url it works, but the CSS / javascript resources do not load. Not sure why I am facing this error.