Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

HTTP::Proxy simply rocks

by polettix (Vicar)
on Dec 19, 2007 at 16:56 UTC ( [id://657913]=CUFP: print w/replies, xml ) Need Help??

Fast! You'd like to download a video from somewhere to put on your brand-new whatever-pod, and you discover that the VideoDownloader in your Firebox doesn't work any more! Well, you can be sane and install something more updated, or you can go Perl with HTTP::Proxy!
#!/usr/bin/env perl use strict; use warnings; use HTTP::Proxy; use HTTP::Proxy::HeaderFilter::simple; $|++; # no buffering on STDOUT please my $proxy = HTTP::Proxy->new(@ARGV); $proxy->push_filter( request => HTTP::Proxy::HeaderFilter::simple->new( sub { print {*STDOUT} $_[2]->uri(), "\n" } ) ); $proxy->start();
Start the proxy in your computer, point the browser to the proxy (it binds on port 8080 by default) and you'll have a list of all visited URIs... included the ones you're really looking for.

Good job, BooK!

Hey! Up to Dec 16, 2007 I was named frodo72, take note of the change! Flavio
perl -ple'$_=reverse' <<<ti.xittelop@oivalf

Io ho capito... ma tu che hai detto?

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: CUFP [id://657913]
Approved by grinder
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (3)
As of 2024-06-22 02:11 GMT
Find Nodes?
    Voting Booth?

    No recent polls found

    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.