Your regular expression should be:
<a class="darklink" .*?>(.*?). - (.*?)</a>
or if you get line breaks inside your <a>
tag:
<a class="darklink" [\s\S]*?>([\s\S]*?). - *([\s\S]*?)</a>
So, following code should works:
Regex person = new Regex(@"<a class=""darklink"" .*?>(.*?). - (.*?)</a>");
foreach (Match m in person.Matches(input))
{
Console.WriteLine("First group : {0}", m.Groups[1]);
Console.WriteLine("Second group: {0}", m.Groups[2]);
};
Rubens Farias
2009-10-14 11:59:12