Gossamer Forum
Home : General : Perl Programming :

Creating a dereferer script ...

Quote Reply
Creating a dereferer script ...
Hi,

i'm playing with a kind of a dereferer-script ... i'd like to "derefer" outgoing hits from my script ... this is what i'm trying now:
Code:
#!/usr/bin/perl -w
use CGI;use CGI::Carp qw(fatalsToBrowser);
use LWP::UserAgent;
$url = 'http://www.google.com';
$version = "0.00";
$referer = "http://www.yahoo.com";
$agent = new LWP::UserAgent;
$agent->agent($version);
$agent->referer($referer);
$request = HTTP::Request->new('GET',$url);
$result = $agent->request($request);
print $result->content();


Any idea why this won't work or how to create a working one?


Thanks for hints
Quote Reply
Re: [TB2] Creating a dereferer script ... In reply to
Im not exactly sure what you mean by:

i'd like to "derefer" outgoing hits from my script
Quote Reply
Re: [Paul] Creating a dereferer script ... In reply to
Hi Paul,

for example:

i'm calling:

www.mydomain.com/cgi-bin/script.cgi?url=http://www.anotherdomain.com

then this url will be saved in the referer-log of anotherdomain.com ... so i'd like to 'redefine' the referer to nothing or anotherdomain.com.