#!/usr/bin/perl use warnings; use strict; use WWW::Mechanize; my $mech = WWW::Mechanize->new(); $mech->timeout(30); $mech->agent_alias('Windows Mozilla'); $mech->get('http://www.lirix.de/unbenannt.html'); my $test = $mech->find_link( class => 'testklasse' ); say $test; #ODER for my $test2 ($mech->find_all_links(class => "testklasse")) { say $test2->text; } }