I am trying to remove the index.php from my URL, and have gone through the necessary steps, and used the code below in my .htaccess file. When I navigate to the homepage, it works, but clicking on any links, or typing their url in manually results in a 404. Just for poops and giggles, I added the index.php into the url of one of the sub-pages, and it started working fine. I've also tried adding the / before index.php in the code below to no avail, and I've tried with and without the ? after index.php. Any help you can provide would be amazing. Also, my site is in a subdirectory, ie, example.com/site-directory/index.php.
<IfModule mod_rewrite.c>
RewriteEngine On
# Removes index.php from ExpressionEngine URLs
RewriteCond $1 !\.(gif|jpe?g|png)$ [NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
</IfModule>
mod_rewrite
enabled?