in reply to Retrieving Links from a HTML Page
This makes no sense whatsoever. You're including an attribute in a tag, and also tacking on some trailing spaces, and your comment indicates you want to look at images, but that doesn't jive with the comparison you're making.sub callback { my($tag, %attr) = @_; return if $tag ne 'a href '; # we only look closer at <img ...> push(@imgs, values %attr); }
|
|---|