/diagnostika%20%D0%B8
RewriteCond %{THE_REQUEST} " /diagnostika%20%D0%B8 "
RewriteRule ^ /diagnostika [R=301,L]
%XX
.RewriteRule "^diagnostika и$" /diagnostika [R=301,L]
Redirect 301 "/diagnostika и" /diagnostika
RedirectMatch 301 "^/diagnostika и$" /diagnostika
RewriteCond %{THE_REQUEST} "^GET / "
RewriteCond %{HTTP:Cookie} !language
RewriteRule ^$ /uk [L,R=302]
# 1 - 99
RewriteRule ^([^/]+)/[1-9]\d?$ /$1/index.php [L]
# 100 - 9999
RewriteRule ^([^/]+)/[1-9]\d\d\d?$ /$1/intel.php [L]
location / {
root /home/apps/project1/public;
}
location /project2 {
alias /home/apps/project2/public;
try_files $uri /index.html =404;
}
location /project3 {
alias /home/apps/project3/public;
try_files $uri /index.html =404;
}
RewriteCond %{THE_REQUEST} " /catalog/index\.html"
RewriteRule ^ /catalog [L,R=301]
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^(|(.+)/)index\.html /$2 [L,R=301]
(?!<p.*?</p>)
поменять на (?!\s*<!-- /wp:paragraph -->\s*<!-- wp:paragraph -->)
preg_match('#^.*\K<p.*?</p>#s', $str, $match);
map $args $replace {
volatile;
default $args;
~^(.*)HELLO(.*) "$1NO$2";
}
server {
location /server/load.php {
rewrite ^ $uri?$replace?;
rewrite ^ $uri?$replace? break;
proxy_pass localhost:88;
proxy_set_header Host $host:$server_port;
proxy_set_header X-Real-IP $remote_addr;
}
/%2/$1
заменить на /folder/%2/$1
VirtualDocumentRoot /var/www/html/folder/%1
<VirtualHost *:80>
DocumentRoot /var/www/html/
ServerName site.ru
ServerAlias www.site.ru
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ $1.php
php_admin_value open_basedir none
</VirtualHost>
<VirtualHost *:80>
UseCanonicalName Off
VirtualDocumentRoot /var/www/html/folder/%1
ServerName site.ru
ServerAlias *.site.ru
<Directory /var/www/html/folder/*/>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ $1.php [L]
</Directory>
php_admin_value open_basedir none
</VirtualHost>