Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

|EASY| Redirect base on referer in .htaccess

Posted on 2008-10-23
2
Medium Priority
?
307 Views
Last Modified: 2012-05-05
I want to redirect people coming from
e.g
http://www.xxx.com/anything.anything
http://xxx.com/anything.anything

to www.google.com
but its not working..
any problem??


RewriteEngine On
RewriteCond %{HTTP_REFERER} ^http://www.xxx.com [NC]
RewriteRule http://www.google.com [NC]
0
Comment
Question by:royalgoldleaf
2 Comments
 
LVL 9

Expert Comment

by:mgonullu
ID: 22787655
0
 
LVL 27

Accepted Solution

by:
caterham_www earned 2000 total points
ID: 22800556
Your rule-pattern is missing
RewriteEngine On
RewriteCond %{HTTP_REFERER} ^http://(www)?\.xxx\.com [NC]
RewriteRule ^  http://www.google.com

Open in new window

0

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
Dramatic changes are revolutionizing how we build and use technology. Every company is automating, digitizing, and modernizing operations. We need a better, more connected way to work together as teams so we can harness the insights from our system…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).
Suggested Courses

972 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question