$mech = new WWW::Mechanize; $mech->get("http://domain.com/page"); print $mech->base; #### for ($mech->links) { print $_->url_abs, "\n"; }