Good day to all. I had a little problem with the site. The sysadmin went on vacation and you have to pick the problems on the server yourself. The problem is this: Previously, the site was running Apache2
. Recently, in view of the need, it was transferred under the control of nginx + php-fastcgi
. The site is working fine. But there was a problem with the display of preview images. They are processed by a special controller. For this in the file. htaccess
was spelled as follows:
SetEnv APPLICATION_ENV production RewriteEngine On #RewriteRule ^.*(files/.*[\.JPG|\.jpg|\.JPEG|\.jpeg|\.GIF|\.gif|\.PNG|\.png])/(w=.*)$ /tools/imagepreview/?$2&f=/$1 [L,QSA] RewriteRule ^(.*[\.JPG|\.jpg|\.JPEG|\.jpeg|\.GIF|\.gif|\.PNG|\.png])/(w=.*)$ /tools/imagepreview/?$2&f=/$1 [L,QSA] RewriteCond %{REQUEST_FILENAME} -s [OR] RewriteCond %{REQUEST_FILENAME} -l [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^.*$ - [NC,L] RewriteRule ^.*$ index.php [NC,L] <IfModule mod_filter.c> <IfModule mod_deflate.c>
My problem is to correctly override the location
for images in nginx
. Help who than can. Thank you in advance!