-6

Need code of php script used for example by mysmartprice dot com on their "Go To Store" button for URL cloaking.

masterwoo
  • 1
  • 1
  • 4
    ehm, what? If you want people to help you, please provide a more detailed explanation (which button?) of your problem and what you have tried so far. – David Müller Nov 25 '12 at 11:03
  • [What have you tried](http://whathaveyoutried)? This seems like a `give me teh codez` type question... – beatgammit Nov 25 '12 at 11:31

1 Answers1

0

I'm not 100% sure if I got your question right, but this is my guess of you mean:

Use PHP's header method like this:

<?php
    if(!isset($_GET["p"]))
        exit("No parameter \"p\"");

    $p = $_GET["p"];
    header("LOCATION: $p");
?>

Save the file as redir.php and then use it as http://mysite.com/redir.php?p=http://google.com/.

Henrik Karlsson
  • 5,559
  • 4
  • 25
  • 42