Everytime I use perl i some how wind up needing to match the smallest occurence of a substr within a string.
$a="< a hhref='http://www.yahoo.com'
name=a>Yahoo!</a><a href ='link.com'>Link</a>";
The result I want is "Yahoo!" but what i actually get is "Yahoo!</a><a href ='link.com'>Link". I realize the regular expression ".*" is the culprit but how do i tell perl to grab the "smallest" matching string and not the default largest matching string? Is it simply replacing ".*" with "[^<]*" for my case or is there another method?