in reply to Re^2: $mech->content() returns empty
in thread $mech->content() returns empty
In theory I could just get that URL, but it'd be a new instance of it when I need to know what the exact source code was once the form was submitted (to check for login errors).
Any other suggestions?
use WWW::Mechanize; my $mech = WWW::Mechanize->new(); $mech->cookie_jar(HTTP::Cookies->new); $mech->get( $forum_login ); if ($forum_type eq "number") { $mech->submit_form( form_number => $forum_call, fields => { $forum_user => $username, $forum_pass => $password, } ); die "Couldn't submit form" unless $mech->success; my $stuff = $mech->content; print $stuff; my $url = $mech->uri; print $url; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: $mech->content() returns empty
by diotalevi (Canon) on Oct 13, 2006 at 23:55 UTC | |
by Anonymous Monk on Oct 14, 2006 at 00:21 UTC | |
by diotalevi (Canon) on Oct 14, 2006 at 00:23 UTC |