ico BUG

btfstone

Member
I use Litespeed+nginx... If I set below
location ~* .(jpg|jpeg|gif|png|swf|htm|html|rar|zip|7z|xml|ico){
root /home/wwwroot/xf4.org/public_html;
expires 30d;
}
Click
2.webp
Error like this.(ps.only Edit Resource Icon error)
1.webp

If I remove |ico
location ~* .(jpg|jpeg|gif|png|swf|htm|html|rar|zip|7z|xml){
root /home/wwwroot/xf4.org/public_html;
expires 30d;
}

Everything is ok...
 
Quick search gave me this:
http://www.nginxtips.com/nginx-location-directive/

However, since you are using a RegEx to match routes, the period (.) matches any character, so /ico in the url to edit the icon matches as well as .ico, thus giving you your 404 error. You should use the following:
location ~* \.(jpg|jpeg|gif|png|swf|htm|html|rar|zip|7z|xml)

It should work.
 
Top Bottom