CodeIgniter Forums
CSS Folder Not Found At Root With Rewrite, but images folder can be - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: CSS Folder Not Found At Root With Rewrite, but images folder can be (/showthread.php?tid=40857)



CSS Folder Not Found At Root With Rewrite, but images folder can be - El Forum - 04-20-2011

[eluser]runs.amock[/eluser]
when I add the following from the manual, into my .htaccess file,
the root level css folder is not found. but when i delete
the .htaccess file, the css folder is found.

Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

but, i can still access the images folder, even with the rewrite code.

my code in the applications folder view file:
Code:
<link href="../css/styles.css" rel="stylesheet" type="text/css" />

do i need to add something to the .htaccess file?

USING: CI 2.0.2, Ubuntu, Latest Xampp


CSS Folder Not Found At Root With Rewrite, but images folder can be - El Forum - 04-20-2011

[eluser]JHackamack[/eluser]
Try:
Code:
RewriteCond $1 !^(index\.php|images|robots\.txt)
to

Code:
RewriteCond $1 !^(index\.php|images|css|robots\.txt)



CSS Folder Not Found At Root With Rewrite, but images folder can be - El Forum - 04-20-2011

[eluser]runs.amock[/eluser]
Worked great. Thanks a bunch.