How to allow access to a file?

#1
Please tell me how to make an exception for some files, access to which is denied through context by type?

There are several types of files, access to which is denied.

Static context:
URI: exp:^.* (log|ini|xml|txt|json)$
Location: $DOC_ROOT/$0
Accessible: No

How to allow access to some files with the xml and txt types. I tried different options, nothing works.
 

Cold-Egg

Administrator
#2
Create another static context using exp: to match the desired XML files, ensure it has a higher priority, and it should work.
 
#3
Cold-Egg, thank you! This is how it works:

Static context:
URL: exp:/sitemap.xml|robots.txt
Location: $DOC_ROOT/$0
Accessible: Yes

It doesn't work without the slash.
 
Top