I’m trying to debug my .htaccess file for http://www.240list.com.
Basically, this is my htaccess file used for my mvc / directory rewrites for files and what not.
Options +FollowSymlinks
RewriteEngine on
RewriteCond %{HTTP_HOST} ^[^\.]+\.[^\.]+$
RewriteRule ^.*$ http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule .* - [L]
RewriteRule ^(\d+\/)?Css/(.*)$ Resources/css/$2 [L]
RewriteRule ^(\d+\/)?Javascript/(.*)$ Libs/Javascript/$2 [L]
RewriteRule ^(\d+\/)?Images/(.*)$ Resources/images/$2 [L]
RewriteRule .*$ App/index.php [L]
The site is not loading my css or images, if you go to the location of an image via what the rewrite url would be, http://www.240list.com/Images/Logo.png for example, it’s redirecting to my index.php because it is loading the autoloader for the mvc framwork, which happens if the first 3 directory rewrite rules don’t match.
The odd thing is, everything was working with the htaccess on my Uniserver I was using for development on my localhost, yet when on hostgator the css and images directories aren’t working yet the JavaScript is. They all have the same directory permissions if that matters.
Any help is appreciated.
It seems not to be working because it’s case sensitive.
Try this:
Just for the record, I always avoid using capital letters in urls and system paths to avoid this kind of errors.
Edit:
I just noted that Javascript is inside Libs and the others are inside Resources. Is it right?