Yeah, your CSS won't work properly because the rewrite rule changes the path for requested files. If you're using relative paths this will mess up your CSS, images and JS.
You can either add rewrite rules for all your CSS and media files or you can access them using the full path starting from your webroot.
Hi,
What if I want to apply the rewrite rule to all the css files under the root directory.. I mean there can be multiple directories having css files so I cannot put web/css specifically for below:
RewriteRule ^([a-z0-9-\s]+)(\.css) web/css/$1.css
Instead, can <FilesMatch> be used to serve the purpose?
Eg, If I need to apply a rewrite rule to redirect my css file to a php file I write as below:
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.