Answer the question
In order to leave comments, you need to log in
How to make nginx analog of regular expression through htaccess?
Tell me how to properly set up a regular expression through .htaccess
Now it works in conjunction: ngnix + php 70 + php-fpm
There is an img.php script that is called according to a certain rule through the nginx config
location /i {
try_files $uri $uri/ /img.php?_url=$uri&$query_string;
}
Answer the question
In order to leave comments, you need to log in
<IfModule mod_rewrite.c>
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !/img.php?$
RewriteRule ^(.*)$ /img.php? [L]
</IfModule>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question