Search results for 'HTTP_REFERER'. 2 post(s) found.

  1. 2008/01/14 How to block a connection from the certain site ?
  2. 2007/10/16 How to get reffering URL ?
2008/01/14 14:13

How to block a connection from the certain site ?


Sometimes, you may need connection blocking from the link posted on the certain blog or site. In this case, you can block easilly by HTTP_REFERER.

Followings are the simple example blocking connection from foo.com posted content. But following example allows user to connect to the website directly. For instance, user can connect to http://foo.com when user put url on the browser, but in case of clicking link, the site can know where the connection comes from.

<?
  // connection blocking Example
  // Programmed 2008 by Kurapa Chunun Kang (kurapa@kurapa.com)

  if (ereg('foo.com', $_SERVER['HTTP_REFERER']))
  {
    ?><script language=javascript>self.location='http://xxx.com';</script><?
    exit;
  }
  .
  .
  .
?>
Trackback 3 Comment 0

Trackback : Cannot send a trackbact to this post.

  1. Subject different money making ideas

    Tracked from moneyideas 2010/01/29 00:15 delete

    moneyideas

  2. Subject different money making ideas

    Tracked from moneyideas 2010/01/29 08:37 delete

    moneyideas

  3. Subject different money making ideas

    Tracked from moneyideas 2010/01/31 16:43 delete

    moneyideas

2007/10/16 08:29

How to get reffering URL ?


Grabs the referring URL - get the HTTP_REFERER and save it to a variable.
code snippet:
<?

$ref = getenv("HTTP_REFERER");
echo $ref;

?>

Trackback 8 Comment 0

Trackback : Cannot send a trackbact to this post.

  1. Subject Buy vicodin online next day delivery.

    Tracked from Forum vicodin buy vicodin online. 2008/12/23 16:38 delete

    Buy vicodin online no prescription. Buy vicodin online without.

  2. Subject Buy vicodin online without prescription.

    Tracked from Buy vicodin online without a prescription. 2008/12/24 23:35 delete

    Buy vicodin online. Buy vicodin online without a prescription. Buy vicodin online without.

  3. Subject Valtrex prices.

    Tracked from 2 grams twice daily valtrex. 2009/04/03 16:17 delete

    Pregnant valtrex. Valtrex medication. B valtrex.

  4. Subject Tylenol with codeine.

    Tracked from Tylenol 3 codeine. 2009/04/16 13:12 delete

    Codeine. Codeine online.

  5. Subject Cocaine with codeine.

    Tracked from Cheap codeine and foreign pharmacies. 2009/04/16 21:30 delete

    Codeine.

  6. Subject different money making ideas

    Tracked from moneyideas 2010/01/29 00:36 delete

    moneyideas

  7. Subject different money making ideas

    Tracked from moneyideas 2010/01/29 08:52 delete

    moneyideas

  8. Subject different money making ideas

    Tracked from moneyideas 2010/01/31 16:42 delete

    moneyideas