CodeIgniter Forums
.htaccess - How to exclude all PNG(s) - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forum-22.html)
+--- Thread: .htaccess - How to exclude all PNG(s) (/thread-40871.html)



.htaccess - How to exclude all PNG(s) - El Forum - 04-21-2011

[eluser]daweb[/eluser]
Hello everybody,

excuse me bad english first.

I have these rules in my .htaccess (Codeigniter 1.7.2):

Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|folder1|htm|captcha|assets|folder2|robots\.txt|favicon\.ico|sitemap\.xml|a-static-file\.html|folder3)
RewriteRule ^(.*)$ /index.php/$1 [L]

I need to exclude all png(s) files from rewriting, but I can't be able to do that.

I did try to add

Code:
|png|
and also
Code:
|*\.png|
but both solutions doesn't works, they returns to me an Internal Server Error.

May I ask your help?

Thank you


.htaccess - How to exclude all PNG(s) - El Forum - 04-21-2011

[eluser]P.T.[/eluser]
(.*)\.png


.htaccess - How to exclude all PNG(s) - El Forum - 04-21-2011

[eluser]daweb[/eluser]
You solve my problem.

Thank you P.T.!


.htaccess - How to exclude all PNG(s) - El Forum - 04-21-2011

[eluser]P.T.[/eluser]
Nice. You're welcome Smile