use HTML::TreeBuilder; my $tree = HTML::TreeBuilder->new_from_content($html); foreach my $img ($tree->look_down('_tag', 'img')) { if ($img->attr('alt')) { print "Alt tag found: ", $img->attr('alt'), "\n"; } } $tree->delete;
gav^
In reply to Re: Extracting ALT text from image links
by gav^
in thread Extracting ALT text from image links
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |