1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

URL 301 based on refer domain

Discussion in 'Black Hat SEO' started by 420friendly, Jan 14, 2016.

  1. 420friendly

    420friendly Regular Member

    Joined:
    Nov 12, 2009
    Messages:
    248
    Likes Received:
    68
    Location:
    Oz
    Is there a way to 301 to a domain based on where the link comes from.?

    Example: domain is 301 forwarded to someurl.com however if the link is from CNN I want it to show the 301 to adifferentdomain.com

    Is this possible via .htaccess
     
  2. rhinocat

    rhinocat Junior Member

    Joined:
    Sep 12, 2013
    Messages:
    181
    Likes Received:
    21
    you can do that using php not sure using .htaccess
     
  3. dystopia

    dystopia Registered Member

    Joined:
    Jan 9, 2016
    Messages:
    74
    Likes Received:
    30
    The only way I can think of this would be, redirecting the pages that were linked to. But if all links are on one page then I don't think you can redirect link juice to two places.
     
  4. 420friendly

    420friendly Regular Member

    Joined:
    Nov 12, 2009
    Messages:
    248
    Likes Received:
    68
    Location:
    Oz
    Yeah they are to the homepage... I am still reading the apache forums... grrrrr there has got to be a way!
     
  5. SexyDuck

    SexyDuck Newbie

    Joined:
    Jan 24, 2016
    Messages:
    9
    Likes Received:
    1
    It has been a long time since I moved to nginx, but something like this should do the trick:

    edit: I cannot post the code as it's being detected as spam... check pastebin 4Rf7zYcE