in reply to WWW::Mechanize and Navigation
Why are you mixing LWP::Simple calls and WWW::Mechanize calls? While both retrieve pages from the web, they cannot easily be mixed?
Here is a way to achieve what you want via WWW::Mechanize through the links() method of the agent, which returns you the list of links on the page, out of which you then can select the links you want:
# After you've submitted your query: my @links = grep { $_->uri =~ m!liste_resultats! } $agent->links; foreach my $link (@links) { print "Retrieving $link\n"; $agent->follow( $link ); print $agent->content; $agent->back; };
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: WWW::Mechanize and Navigation
by New Novice (Sexton) on Nov 25, 2004 at 20:23 UTC | |
by Corion (Patriarch) on Nov 25, 2004 at 20:26 UTC | |
by New Novice (Sexton) on Nov 26, 2004 at 15:58 UTC | |
by New Novice (Sexton) on Nov 27, 2004 at 10:00 UTC |