views:

379

answers:

1

Can you help me with an Apache rule to exclude a particular file name or type of file? Here are my current rules:

RewriteRule ^/(?:blog)/ - [L]
RewriteRule ^crossdomain\.xml$ - [L]  (Based on first response)
RewriteRule ^/(.*_css.*\.css.*) /$1 [QSA,L]
RewriteRule ^/(.*_js.*\.js.*) /$1 [QSA,L]
RewriteRule ^/(.*_swf.*\.swf.*) /$1 [QSA,L]
RewriteRule ^/(.*_img.*\.[jpg|JPG|jpeg|JPEG|gif|GIF|bmp|BMP|png|PNG].*) /$1 [QSA,L]
RewriteRule ^/(.*)$ /index.php?url=$1 [QSA,L]
</VirtualHost>

I am trying to exclude my Flash crossdomain.xml file from getting rewritten. Thanks!

A: 

Just put this rule on top of yours:

RewriteRule ^/crossdomain\.xml$ - [L]
Gumbo
Hey Gumbo, I added the line you requested as you can see above. But I still get redirected when I try and access the crossdomain.xml file. Any other thoughts?
roacha
Awesome, worked. Thanks Gumbo!
roacha