You are here: Re: Changing Referer « PHP « IT news, forums, messages
Re: Changing Referer

Posted by Pro N00b on 03/15/05 22:05

Cav wrote:
> Hi,
>
> since i didn't find a solution for my problem I decided to ask here. I
> want to change HTTP_REFERER, this is how my scripts look like:
>
> a.php
> ---------
> <?php
> header("referer: http://www.asd.com");
> $asd = curl_init();
> curl_setopt($asd, CURLOPT_REFERER, "http://www.asd.com");
> curl_exec($asd);
> curl_close($asd);
> ?>
> <a href="b.php"> check </a>
>
>
> b.php
> ---------
> <?php
> echo "referrer = " . $_SERVER['HTTP_REFERER'];
> ?>
>
> who can tell me what did I do wrong? why b.php still shows as referer
> a.php and not asd.com? Sorry if my question is too simple but I'm a
> php-newbie and can't find the right answer on google ;)
>
> Greetings

The browser always sends the sending form as refer, there's no way to
avoid this (except writing your own browser).
I would use a hidden form field or GET variabele for this

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация