in reply to Intercepting the HTTP::Request

If you're trying to re-define WWW::Mechanize's _make_request method, maybe
... package WWW::Mechanize; sub _make_request { my($self) = shift; my $req = $self->SUPER::request(@_); print Dumper $req; return $req } ...
is what you want ? Another possible problem might be that you suppose that WWW::Mechanize's STDOUT (where Dumper would write to) is something that comes in handy to you. That isn't really granted ;)

Replies are listed 'Best First'.
Re^2: Intercepting the HTTP::Request
by rootcho (Pilgrim) on May 16, 2007 at 16:56 UTC
    No, I tried this too, also didn't work.. But I've done what I want this way :
    http://perlmonks.org/?node_id=615669
    Even that I would liked to do it trough, this way it wouldn't involve using external module.