(?s).*?(page\.php\?id=\d+|\z)
$1\n
RewriteCond %{THE_REQUEST} " /current/public/(\S*)"
RewriteRule ^ https://%{HTTP_HOST}/%1 [R=301,L,NE]
'~(<h3>(?:(?!</?h3).)*</h3>)((?:(?!my-class).)*?)(<p>.*?</p>)~is'
'~(<h3>.*?</h3>)((?:my-class(*SKIP)(*F)|.)*?)(<p>.*?</p>)~is'
'~(?>(<h3>.*?</h3>)((?:my-class()|.)*?)(<p>.*?</p>))(?!\3)~is'
//l27.0.0
RewriteCond %{HTTP_HOST} ^(www\.|)oldsite\.ru$ [NC]
RewriteRule ^(category1|category2)/.* http://newsite.ru/$0 [R=301,L]
RewriteCond %{HTTP_HOST} ^(www\.|)oldsite\.ru$ [NC]
RewriteRule ^ http://newsite.ru/ [R=301,L]
location ^~ /files/ {
if (!-e $request_filename){
return 301 http://images.site.ru$uri;
}
}
location ^~ /files/ {
try_files $uri =404;
error_page 404 =301 http://images.site.ru$uri;
}
location ~ /(wp-login|admin)\.php {
set $humantest 0;
if ($http_cookie !~* "humans=checktest") {
set $humantest 1;
}
if ($args ~* (callback|logout|lostpassword)) {
set $humantest 0;
}
if ($humantest = 1) {
add_header Content-Type text/html;
return 200 "<html><body><script>document.cookie='humans=checktest;path=/';location.reload();</script></body></html>";
}
error_page 404 = @fallback;
include fastcgi_params;
fastcgi_pass ...
}
location ~ \.php
server {
listen 80;
server_name xxx.ru;
root /var/www/html/vfm;
index index.php;
location ~ \.php$ {
include /etc/nginx/fastcgi.conf;
fastcgi_pass fastcgi_backend_71;
}
location ^~ /hite {
root /var/www/html;
location ~ \.php$ {
include /etc/nginx/fastcgi.conf;
fastcgi_pass fastcgi_backend_71;
}
}
}
rewrite ^/(?:(.*)/|)index\.(?:php|htm) /$1 permanent;
rewrite ^/(.*)\.(php|htm) /$1 permanent;
rewrite ^/(.*)/$ /$1 permanent;
rewrite ^/page/([^/]*)$ /page.php?param=$1;
rewrite ^/$ /index.php;
location ~ \.php$ {
include fastcgi.conf;
fastcgi_pass unix:/run/php/php7.2-fpm.sock;
}
location / {
try_files $uri @extensionless-php;
}
location @extensionless-php {
try_files $uri.php $uri/index.php =404;
include fastcgi.conf;
fastcgi_pass unix:/run/php/php7.2-fpm.sock;
}
error_page 404 /error;