# loop through the current page's links and use ->follow_link( text_regex => q/$_/i to find and follow the current link #### for my $link ($mech->find_all_links) { # on this page $mech->get($link->url); unless ($mech->success) { warn "can't get ".$link->url.", status: ".$mech->status; } $mech->back; }