Javascript-форум (https://javascript.ru/forum/)
-   Серверные языки и технологии (https://javascript.ru/forum/server/)
-   -   .htaccess Запретить доступ с реферов (https://javascript.ru/forum/server/60513-htaccess-zapretit-dostup-s-referov.html)

Duda.Ml1986@gmail.com 04.01.2016 15:28

.htaccess Запретить доступ с реферов
 
Проблема в следующем:

.htaccess:

RewriteEngine on
RewriteBase /

RewriteCond %{HTTP_HOST} !^example\.com
RewriteRule ^(.*)$ http://example.com/$1 [R=301,L]

RewriteRule ^page([0-9]+).html$ index.php?page=$1

RewriteRule ^p([0-9]+)-([a-zA-Z0-9_]+).html$ index.php?id_post=$1&title_post=$2
RewriteRule ^([a-zA-Z0-9_\-]+)/page([0-9]+).html$ index.php?mpoint=$1&page=$2 [L]
RewriteRule ^([a-zA-Z0-9_\-]+).html$ index.php?mpoint=$1
RewriteRule ^.*.html$ index.php?mpoint=$1


RewriteCond %{HTTP_REFERER} ^www.example111.com$ [NC,OR]
RewriteCond %{HTTP_REFERER} ^example222.ml$ 
RewriteRule .* – [F]


index.php

echo $_SERVER['HTTP_REFERER'];


result: http://www.example111.com/xxxx/yyy.html

ПОчему я это вижу и правило RewriteCond Не работает?


Часовой пояс GMT +3, время: 09:30.