I have a website with a wordpress installation and I’m using modrewrite to display clean urls. I want the visitors that are comming from facebook to access the site , while the others redirected to other , i made one , its working , but i am not sure how to redirect the denied visitors to the other site
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
RewriteCond %{HTTP_REFERER} !(www.)?facebook.com
RewriteCond %{HTTP_REFERER} !(www.)?fb.com
RewriteCond %{HTTP_REFERER} !(www.)?l.facebook.com
RewriteCond %{HTTP_REFERER} !(www.)?goo.gl
RewriteRule .* - [F]
Your
RewriteRule
should have a full URL of the one that you want to redirect to.For example: